Version 1.22.0-dev.0.0

Merge b214f5fa7e472d22b8c294c0ca8dc09fe5a727e2 into dev
diff --git a/.gitignore b/.gitignore
index a0b469f..8cdeac8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -21,6 +21,7 @@
 *.vcxproj
 *.vcxproj.filters
 /*.vcxproj.user
+*.stamp
 
 # Gyp generated files
 *.xcodeproj
diff --git a/CHANGELOG.md b/CHANGELOG.md
index b90703a..f573d16 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,4 +1,4 @@
-## 1.21.0
+## 1.21.0 - 2016-12-07
 
 ### Language
 
@@ -20,8 +20,11 @@
 
 * `dart:core`: `Set.difference` now takes a `Set<Object>` as argument.
 
-* `dart:developer`:
-  * The service protocol http server can now be controlled from Dart code.
+* `dart:developer`
+
+  * Added `Service` class.
+    * Allows inspecting and controlling the VM service protocol HTTP server.
+    * Provides an API to access the ID of an `Isolate`.
 
 ### Tool changes
 
diff --git a/DEPS b/DEPS
index 4f5d541..affb687 100644
--- a/DEPS
+++ b/DEPS
@@ -73,7 +73,7 @@
   "isolate_tag": "@0.2.3",
   "jinja2_rev": "@2222b31554f03e62600cd7e383376a7c187967a1",
   "json_rpc_2_tag": "@2.0.2",
-  "linter_tag": "@0.1.29",
+  "linter_rev": "@b2d95da1287e27d4dbb9bd199dd2d23d650bd274",
   "logging_tag": "@0.11.3+1",
   "markdown_tag": "@0.11.0",
   "matcher_tag": "@0.12.0+2",
@@ -235,7 +235,7 @@
   Var("dart_root") + "/third_party/pkg/json_rpc_2":
       (Var("github_mirror") % "json_rpc_2") + Var("json_rpc_2_tag"),
   Var("dart_root") + "/third_party/pkg/linter":
-      (Var("github_mirror") % "linter") + Var("linter_tag"),
+      (Var("github_mirror") % "linter") + Var("linter_rev"),
   Var("dart_root") + "/third_party/pkg/logging":
       (Var("github_mirror") % "logging") + Var("logging_tag"),
   Var("dart_root") + "/third_party/pkg/markdown":
diff --git a/docs/language/dartLangSpec.tex b/docs/language/dartLangSpec.tex
index a01d8eb2..8232a3b 100644
--- a/docs/language/dartLangSpec.tex
+++ b/docs/language/dartLangSpec.tex
@@ -1390,8 +1390,7 @@
 \LMHash{}
 Then if any instance variable of $i$ declared by the immediately enclosing class
 is not yet bound to a value,
-it is a dynamic error if such a variable is a \FINAL{} variable,
-otherwise all such variables are initialized with the \NULL{} value.
+all such variables are initialized with the \NULL{} value.
 
 \LMHash{}
 Then, unless the enclosing class is \code{Object}, the explicitly specified or
diff --git a/pkg/analysis_server/benchmark/perf/benchmark_angular.dart b/pkg/analysis_server/benchmark/perf/benchmark_angular.dart
new file mode 100644
index 0000000..d1effe1
--- /dev/null
+++ b/pkg/analysis_server/benchmark/perf/benchmark_angular.dart
@@ -0,0 +1,117 @@
+// 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.
+
+library server.performance.local;
+
+import 'dart:async';
+
+import 'benchmark_scenario.dart';
+import 'memory_tests.dart';
+
+main(List<String> args) async {
+  int length = args.length;
+  if (length < 1) {
+    print(
+        'Usage: dart benchmark_local.dart path_to_np8080 (an example ngdart project)'
+        ' [benchmark_id]');
+    return;
+  }
+  paths = new PathHolder(projectPath: args[0]);
+  String id = args.length >= 2 ? args[1] : null;
+  if (id == null) {
+    for (String id in benchmarks.keys) {
+      BenchmarkFunction benchmark = benchmarks[id];
+      await benchmark(id);
+    }
+  } else {
+    BenchmarkFunction benchmark = benchmarks[id];
+    if (benchmark != null) {
+      benchmark(id);
+    }
+  }
+}
+
+const Map<String, BenchmarkFunction> benchmarks =
+    const <String, BenchmarkFunction>{
+  'ng-initialAnalysis': run_ng_initialAnalysis,
+  'ng-change-dart': run_ng_change_dart,
+  'ng-change-html': run_ng_change_html,
+  'ng-memory-initialAnalysis': run_ng_memory_initialAnalysis,
+};
+
+PathHolder paths;
+
+Future run_ng_change_dart(String id) async {
+  String description = r'''
+1. Open 'packages/np8080'.
+2. Add an @Output to the class
+3. Measure the time to finish analysis.
+4. Rollback changes to the file and wait for analysis.
+5. Go to (2).
+''';
+  List<int> times = await new BenchmarkScenario().waitAnalyze_change_analyze(
+      roots: [paths.packageNp8080],
+      file: paths.editorDart,
+      fileChange: new FileChange(
+          afterStr: 'showPreview = false;',
+          insertStr: '@Output() EventEmitter<int> myEventEmitter;'),
+      numOfRepeats: 10);
+  printBenchmarkResults(id, description, times);
+}
+
+Future run_ng_change_html(String id) async {
+  String description = r'''
+1. Open 'packages/np8080'.
+2. Change the contents of a mustache
+3. Measure the time to finish analysis.
+4. Rollback changes to the file and wait for analysis.
+5. Go to (2).
+''';
+  List<int> times = await new BenchmarkScenario().waitAnalyze_change_analyze(
+      roots: [paths.packageNp8080],
+      file: paths.editorHtml,
+      fileChange: new FileChange(
+          afterStr: 'note.lastModified', afterStrBack: 4, insertStr: 'NewName'),
+      numOfRepeats: 4);
+  printBenchmarkResults(id, description, times);
+}
+
+Future run_ng_initialAnalysis(String id) async {
+  String description = r'''
+1. Start server, set 'package/np8080' analysis roots.
+2. Measure the time to finish initial analysis.
+3. Shutdown the server.
+4. Go to (1).
+''';
+  List<int> times = await BenchmarkScenario.start_waitInitialAnalysis_shutdown(
+      roots: [paths.packageNp8080], numOfRepeats: 5);
+  printBenchmarkResults(id, description, times);
+}
+
+Future run_ng_memory_initialAnalysis(String id) async {
+  String description = r'''
+1. Start server, set 'package/np8080' as the analysis root.
+2. Measure the memory usage after finishing initial analysis.
+3. Shutdown the server.
+4. Go to (1).
+''';
+  List<int> sizes = await AnalysisServerMemoryUsageTest
+      .start_waitInitialAnalysis_shutdown(
+          roots: <String>[paths.packageNp8080], numOfRepeats: 3);
+  printMemoryResults(id, description, sizes);
+}
+
+typedef BenchmarkFunction(String id);
+
+class PathHolder {
+  String editorHtml;
+  String editorDart;
+  String packageNp8080;
+
+  PathHolder({String projectPath}) {
+    editorHtml = '$projectPath/lib/editor/editor_component.html';
+    editorDart = '$projectPath/lib/editor/editor_component.dart';
+    packageNp8080 = projectPath;
+  }
+}
diff --git a/pkg/analysis_server/lib/plugin/edit/fix/fix_dart.dart b/pkg/analysis_server/lib/plugin/edit/fix/fix_dart.dart
index a0527d6..7b5d3d5 100644
--- a/pkg/analysis_server/lib/plugin/edit/fix/fix_dart.dart
+++ b/pkg/analysis_server/lib/plugin/edit/fix/fix_dart.dart
@@ -9,9 +9,20 @@
 import 'package:analysis_server/plugin/edit/fix/fix_core.dart';
 import 'package:analysis_server/src/services/correction/fix_internal.dart'
     show DartFixContextImpl;
+import 'package:analysis_server/src/services/correction/namespace.dart'
+    show getExportedElement;
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/src/dart/analysis/top_level_declaration.dart';
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/source.dart';
+import 'package:analyzer/src/task/dart.dart' show LIBRARY_ELEMENT4;
+
+/**
+ * Complete with top-level declarations with the given [name].
+ */
+typedef Future<List<TopLevelDeclarationInSource>> GetTopLevelDeclarations(
+    String name);
 
 /**
  * An object used to provide context information for [DartFixContributor]s.
@@ -20,6 +31,11 @@
  */
 abstract class DartFixContext implements FixContext {
   /**
+   * The function to get top-level declarations from.
+   */
+  GetTopLevelDeclarations get getTopLevelDeclarations;
+
+  /**
    * The [CompilationUnit] to compute fixes in.
    */
   CompilationUnit get unit;
@@ -48,7 +64,8 @@
     if (unit == null) {
       return Fix.EMPTY_LIST;
     }
-    DartFixContext dartContext = new DartFixContextImpl(context, unit);
+    DartFixContext dartContext = new DartFixContextImpl(
+        context, _getTopLevelDeclarations(analysisContext), unit);
     return internalComputeFixes(dartContext);
   }
 
@@ -56,4 +73,43 @@
    * Return a list of fixes for the given [context].
    */
   Future<List<Fix>> internalComputeFixes(DartFixContext context);
+
+  GetTopLevelDeclarations _getTopLevelDeclarations(AnalysisContext context) {
+    return (String name) async {
+      List<TopLevelDeclarationInSource> declarations = [];
+      List<Source> librarySources = context.librarySources;
+      for (Source librarySource in librarySources) {
+        // Prepare the LibraryElement.
+        LibraryElement libraryElement =
+            context.getResult(librarySource, LIBRARY_ELEMENT4);
+        if (libraryElement == null) {
+          continue;
+        }
+        // Prepare the exported Element.
+        Element element = getExportedElement(libraryElement, name);
+        if (element == null) {
+          continue;
+        }
+        if (element is PropertyAccessorElement) {
+          element = (element as PropertyAccessorElement).variable;
+        }
+        // Add a new declaration.
+        TopLevelDeclarationKind topLevelKind;
+        if (element.kind == ElementKind.CLASS ||
+            element.kind == ElementKind.FUNCTION_TYPE_ALIAS) {
+          topLevelKind = TopLevelDeclarationKind.type;
+        } else if (element.kind == ElementKind.FUNCTION) {
+          topLevelKind = TopLevelDeclarationKind.function;
+        } else if (element.kind == ElementKind.TOP_LEVEL_VARIABLE) {
+          topLevelKind = TopLevelDeclarationKind.variable;
+        }
+        if (topLevelKind != null) {
+          bool isExported = element.librarySource != librarySource;
+          declarations.add(new TopLevelDeclarationInSource(librarySource,
+              new TopLevelDeclaration(topLevelKind, element.name), isExported));
+        }
+      }
+      return declarations;
+    };
+  }
 }
diff --git a/pkg/analysis_server/lib/src/analysis_server.dart b/pkg/analysis_server/lib/src/analysis_server.dart
index c8afeae..8f22907 100644
--- a/pkg/analysis_server/lib/src/analysis_server.dart
+++ b/pkg/analysis_server/lib/src/analysis_server.dart
@@ -367,7 +367,20 @@
         options.finerGrainedInvalidation;
     defaultContextOptions.generateImplicitErrors = false;
     operationQueue = new ServerOperationQueue();
-    _analysisPerformanceLogger = new nd.PerformanceLog(io.stdout);
+
+    {
+      String name = options.newAnalysisDriverLog;
+      StringSink sink = new _NullStringSink();
+      if (name != null) {
+        if (name == 'stdout') {
+          sink = io.stdout;
+        } else if (name.startsWith('file:')) {
+          String path = name.substring('file:'.length);
+          sink = new io.File(path).openWrite(mode: io.FileMode.APPEND);
+        }
+      }
+      _analysisPerformanceLogger = new nd.PerformanceLog(sink);
+    }
     if (resourceProvider is PhysicalResourceProvider) {
       byteStore = new MemoryCachingByteStore(
           new FileByteStore(
@@ -381,6 +394,7 @@
         new nd.AnalysisDriverScheduler(_analysisPerformanceLogger);
     analysisDriverScheduler.status.listen(sendStatusNotificationNew);
     analysisDriverScheduler.start();
+
     if (useSingleContextManager) {
       contextManager = new SingleContextManager(resourceProvider, sdkManager,
           packageResolverProvider, analyzedFilesGlobs, defaultContextOptions);
@@ -618,8 +632,14 @@
     if (result != null) {
       return result;
     }
-    nd.AnalysisDriver driver = getAnalysisDriver(path);
-    return driver?.getResult(path);
+    try {
+      nd.AnalysisDriver driver = getAnalysisDriver(path);
+      return await driver?.getResult(path);
+    } catch (e) {
+      // Ignore the exception.
+      // We don't want to log the same exception again and again.
+      return null;
+    }
   }
 
   CompilationUnitElement getCompilationUnitElement(String file) {
@@ -894,7 +914,7 @@
    * Return `true` if analysis is complete.
    */
   bool isAnalysisComplete() {
-    return operationQueue.isEmpty;
+    return operationQueue.isEmpty && !analysisDriverScheduler.isAnalyzing;
   }
 
   /**
@@ -1139,10 +1159,14 @@
   }
 
   /**
-   * Send status notification to the client. The `operation` is the operation
-   * being performed or `null` if analysis is complete.
+   * Send status notification to the client. The state of analysis is given by
+   * the [status] information.
    */
   void sendStatusNotificationNew(nd.AnalysisStatus status) {
+    if (_onAnalysisCompleteCompleter != null && !status.isAnalyzing) {
+      _onAnalysisCompleteCompleter.complete();
+      _onAnalysisCompleteCompleter = null;
+    }
     // Only send status when subscribed.
     if (!serverServices.contains(ServerService.STATUS)) {
       return;
@@ -1197,7 +1221,7 @@
           // The result will be produced by the "results" stream with
           // the fully resolved unit, and processed with sending analysis
           // notifications as it happens after content changes.
-          driver.getResult(file);
+          driver.getResult(file).catchError((exception, stackTrace) {});
         }
       }
       return;
@@ -1733,6 +1757,7 @@
   bool noIndex = false;
   bool useAnalysisHighlight2 = false;
   String fileReadMode = 'as-is';
+  String newAnalysisDriverLog;
 }
 
 /**
@@ -1833,6 +1858,10 @@
       // OCCURRENCES (not used in IDEA)
       // OUTLINE (not used in IDEA)
     });
+    analysisDriver.exceptions.listen((nd.ExceptionResult result) {
+      AnalysisEngine.instance.logger
+          .logError('Analysis failed: ${result.path}', result.exception);
+    });
     analysisServer.driverMap[folder] = analysisDriver;
     return analysisDriver;
   }
@@ -1881,6 +1910,12 @@
   }
 
   @override
+  void applyFileRemoved(nd.AnalysisDriver driver, String file) {
+    driver.removeFile(file);
+    sendAnalysisNotificationFlushResults(analysisServer, [file]);
+  }
+
+  @override
   void computingPackageMap(bool computing) =>
       analysisServer._computingPackageMap(computing);
 
@@ -1929,6 +1964,11 @@
       sendAnalysisNotificationFlushResults(analysisServer, flushedFiles);
       nd.AnalysisDriver driver = analysisServer.driverMap.remove(folder);
       driver.dispose();
+      // Remove cached priority results for the driver.
+      var results = analysisServer.priorityFileResults;
+      results.keys
+          .where((key) => results[key].driver == driver)
+          .forEach(results.remove);
     } else {
       AnalysisContext context = analysisServer.folderMap.remove(folder);
       sendAnalysisNotificationFlushResults(analysisServer, flushedFiles);
@@ -2070,3 +2110,10 @@
    */
   static PerformanceTag splitStore = new PerformanceTag('splitStore');
 }
+
+class _NullStringSink implements StringSink {
+  void write(Object obj) {}
+  void writeAll(Iterable objects, [String separator = ""]) {}
+  void writeCharCode(int charCode) {}
+  void writeln([Object obj = ""]) {}
+}
diff --git a/pkg/analysis_server/lib/src/context_manager.dart b/pkg/analysis_server/lib/src/context_manager.dart
index 19737b8..4333b45 100644
--- a/pkg/analysis_server/lib/src/context_manager.dart
+++ b/pkg/analysis_server/lib/src/context_manager.dart
@@ -34,6 +34,9 @@
 import 'package:analyzer/src/util/absolute_path.dart';
 import 'package:analyzer/src/util/glob.dart';
 import 'package:analyzer/src/util/yaml.dart';
+import 'package:linter/src/config.dart';
+import 'package:linter/src/linter.dart';
+import 'package:linter/src/rules.dart';
 import 'package:package_config/packages.dart';
 import 'package:package_config/packages_file.dart' as pkgfile show parse;
 import 'package:package_config/src/packages_impl.dart' show MapPackages;
@@ -343,6 +346,11 @@
   AnalysisContext addContext(Folder folder, AnalysisOptions options);
 
   /**
+   * The given [file] was removed from the folder analyzed in the [driver].
+   */
+  void applyFileRemoved(AnalysisDriver driver, String file);
+
+  /**
    * Called when the set of files associated with a context have changed (or
    * some of those files have been modified).  [changeSet] is the set of
    * changes that need to be applied to the context.
@@ -683,7 +691,7 @@
     if (options == null && !optionsRemoved) {
       return;
     }
-    AnalysisOptions analysisOptions = info.analysisDriver.analysisOptions;
+    AnalysisOptionsImpl analysisOptions = info.analysisDriver.analysisOptions;
 
     // In case options files are removed, revert to defaults.
     if (optionsRemoved) {
@@ -703,18 +711,15 @@
       }
     }
 
-    // TODO(brianwilkerson) Figure out what to do here.
-//    // Notify options processors.
-//    AnalysisEngine.instance.optionsPlugin.optionsProcessors
-//        .forEach((OptionsProcessor p) {
-//      try {
-//        p.optionsProcessed(info.context, options);
-//      } catch (e, stacktrace) {
-//        AnalysisEngine.instance.logger.logError(
-//            'Error processing analysis options',
-//            new CaughtException(e, stacktrace));
-//      }
-//    });
+    var lintOptions = options['linter'];
+    if (lintOptions != null) {
+      LintConfig config = new LintConfig.parseMap(lintOptions);
+      Iterable<LintRule> lintRules = ruleRegistry.enabled(config);
+      if (lintRules.isNotEmpty) {
+        analysisOptions.lint = true;
+        analysisOptions.lintRules = lintRules.toList();
+      }
+    }
 
     applyToAnalysisOptions(analysisOptions, options);
 
@@ -1479,7 +1484,7 @@
         }
 
         if (enableNewAnalysisDriver) {
-          info.analysisDriver.removeFile(path);
+          callbacks.applyFileRemoved(info.analysisDriver, path);
         } else {
           List<Source> sources = info.context.getSourcesWithFullName(path);
           if (!sources.isEmpty) {
diff --git a/pkg/analysis_server/lib/src/edit/edit_domain.dart b/pkg/analysis_server/lib/src/edit/edit_domain.dart
index 1cde3a7..d7714fe 100644
--- a/pkg/analysis_server/lib/src/edit/edit_domain.dart
+++ b/pkg/analysis_server/lib/src/edit/edit_domain.dart
@@ -189,7 +189,11 @@
           int errorLine = lineInfo.getLocation(error.offset).lineNumber;
           if (errorLine == requestLine) {
             var context = new _DartFixContextImpl(
-                server.resourceProvider, unit.element.context, unit, error);
+                server.resourceProvider,
+                result.driver.getTopLevelNameDeclarations,
+                unit.element.context,
+                unit,
+                error);
             List<Fix> fixes =
                 await new DefaultFixContributor().internalComputeFixes(context);
             if (fixes.isNotEmpty) {
@@ -406,8 +410,8 @@
       if (element != null) {
         // try CONVERT_METHOD_TO_GETTER
         if (element is ExecutableElement) {
-          Refactoring refactoring =
-              new ConvertMethodToGetterRefactoring(searchEngine, element);
+          Refactoring refactoring = new ConvertMethodToGetterRefactoring(
+              searchEngine, _getResolvedUnit, element);
           RefactoringStatus status = await refactoring.checkInitialConditions();
           if (!status.hasFatalError) {
             kinds.add(RefactoringKind.CONVERT_METHOD_TO_GETTER);
@@ -440,11 +444,17 @@
     return Response.DELAYED_RESPONSE;
   }
 
+  Future<CompilationUnit> _getResolvedUnit(Element element) {
+    String path = element.source.fullName;
+    return server.getResolvedCompilationUnit(path);
+  }
+
   /**
    * Initializes [refactoringManager] with a new instance.
    */
   void _newRefactoringManager() {
-    refactoringManager = new _RefactoringManager(server, searchEngine);
+    refactoringManager =
+        new _RefactoringManager(server, _getResolvedUnit, searchEngine);
   }
 
   static int _getNumberOfScanParseErrors(List<engine.AnalysisError> errors) {
@@ -491,6 +501,9 @@
   final ResourceProvider resourceProvider;
 
   @override
+  final GetTopLevelDeclarations getTopLevelDeclarations;
+
+  @override
   final engine.AnalysisContext analysisContext;
 
   @override
@@ -499,8 +512,8 @@
   @override
   final engine.AnalysisError error;
 
-  _DartFixContextImpl(
-      this.resourceProvider, this.analysisContext, this.unit, this.error);
+  _DartFixContextImpl(this.resourceProvider, this.getTopLevelDeclarations,
+      this.analysisContext, this.unit, this.error);
 }
 
 /**
@@ -518,6 +531,7 @@
       const <RefactoringProblem>[];
 
   final AnalysisServer server;
+  final GetResolvedUnit getResolvedUnit;
   final SearchEngine searchEngine;
   StreamSubscription subscriptionToReset;
 
@@ -534,7 +548,7 @@
   Request request;
   EditGetRefactoringResult result;
 
-  _RefactoringManager(this.server, this.searchEngine) {
+  _RefactoringManager(this.server, this.getResolvedUnit, this.searchEngine) {
     _reset();
   }
 
@@ -726,8 +740,8 @@
       if (element != null) {
         if (element is ExecutableElement) {
           _resetOnAnalysisStarted();
-          refactoring =
-              new ConvertMethodToGetterRefactoring(searchEngine, element);
+          refactoring = new ConvertMethodToGetterRefactoring(
+              searchEngine, getResolvedUnit, element);
         }
       }
     }
@@ -763,11 +777,8 @@
       CompilationUnit unit = await server.getResolvedCompilationUnit(file);
       if (unit != null) {
         _resetOnAnalysisStarted();
-        refactoring =
-            new InlineMethodRefactoring(searchEngine, (Element element) async {
-          String elementPath = element.source.fullName;
-          return await server.getResolvedCompilationUnit(elementPath);
-        }, unit, offset);
+        refactoring = new InlineMethodRefactoring(
+            searchEngine, getResolvedUnit, unit, offset);
       }
     }
     if (kind == RefactoringKind.MOVE_FILE) {
diff --git a/pkg/analysis_server/lib/src/search/search_domain.dart b/pkg/analysis_server/lib/src/search/search_domain.dart
index 9031325..3dffbad 100644
--- a/pkg/analysis_server/lib/src/search/search_domain.dart
+++ b/pkg/analysis_server/lib/src/search/search_domain.dart
@@ -141,21 +141,15 @@
    * Implement the `search.getTypeHierarchy` request.
    */
   Future getTypeHierarchy(protocol.Request request) async {
-    if (server.options.enableNewAnalysisDriver) {
-      // TODO(scheglov) implement for the new analysis driver
-      protocol.Response response =
-          new protocol.SearchGetTypeHierarchyResult(hierarchyItems: [])
-              .toResponse(request.id);
-      server.sendResponse(response);
-      return;
-    }
     var params = new protocol.SearchGetTypeHierarchyParams.fromRequest(request);
     String file = params.file;
     // wait for analysis
-    if (params.superOnly == true) {
-      await server.onFileAnalysisComplete(file);
-    } else {
-      await server.onAnalysisComplete;
+    if (!server.options.enableNewAnalysisDriver) {
+      if (params.superOnly == true) {
+        await server.onFileAnalysisComplete(file);
+      } else {
+        await server.onAnalysisComplete;
+      }
     }
     // prepare element
     Element element = await server.getElementAtOffset(file, params.offset);
diff --git a/pkg/analysis_server/lib/src/server/driver.dart b/pkg/analysis_server/lib/src/server/driver.dart
index f813e78..2f180ee 100644
--- a/pkg/analysis_server/lib/src/server/driver.dart
+++ b/pkg/analysis_server/lib/src/server/driver.dart
@@ -243,7 +243,7 @@
       "incremental-resolution-validation";
 
   /**
-   * The name of the option used to enable using pub summary manager.
+   * The name of the option used to enable using the new analysis driver.
    */
   static const String ENABLE_NEW_ANALYSIS_DRIVER = 'enable-new-analysis-driver';
 
@@ -276,6 +276,11 @@
   static const String INTERNAL_PRINT_TO_CONSOLE = "internal-print-to-console";
 
   /**
+   * The name of the option used to describe the new analysis driver logger.
+   */
+  static const String NEW_ANALYSIS_DRIVER_LOG = 'new-analysis-driver-log';
+
+  /**
    * The name of the flag used to disable error notifications.
    */
   static const String NO_ERROR_NOTIFICATION = "no-error-notification";
@@ -399,6 +404,8 @@
     analysisServerOptions.useAnalysisHighlight2 =
         results[USE_ANALISYS_HIGHLIGHT2];
     analysisServerOptions.fileReadMode = results[FILE_READ_MODE];
+    analysisServerOptions.newAnalysisDriverLog =
+        results[NEW_ANALYSIS_DRIVER_LOG];
 
     _initIncrementalLogger(results[INCREMENTAL_RESOLUTION_LOG]);
 
@@ -559,6 +566,8 @@
         help: "enable sending `print` output to the console",
         defaultsTo: false,
         negatable: false);
+    parser.addOption(NEW_ANALYSIS_DRIVER_LOG,
+        help: "set a destination for the new analysis driver's log");
     parser.addOption(PORT_OPTION,
         help: "the http diagnostic port on which the server provides"
             " status and performance information");
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 e00ec2a..26a9af5 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
@@ -19,6 +19,7 @@
 import 'package:analysis_server/src/services/completion/dart/optype.dart';
 import 'package:analysis_server/src/services/search/search_engine.dart';
 import 'package:analyzer/dart/ast/ast.dart';
+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/type.dart';
@@ -516,7 +517,8 @@
         }
       }
       if (token is StringToken) {
-        SimpleStringLiteral uri = new SimpleStringLiteral(token, token.lexeme);
+        SimpleStringLiteral uri =
+            astFactory.simpleStringLiteral(token, token.lexeme);
         Keyword keyword = token.previous?.keyword;
         if (keyword == Keyword.IMPORT ||
             keyword == Keyword.EXPORT ||
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/label_contributor.dart b/pkg/analysis_server/lib/src/services/completion/dart/label_contributor.dart
index 8600be2..a540887 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/label_contributor.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/label_contributor.dart
@@ -15,6 +15,7 @@
     show LocalDeclarationVisitor;
 import 'package:analysis_server/src/services/completion/dart/optype.dart';
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/src/dart/ast/token.dart';
 import 'package:analyzer/src/generated/source.dart';
@@ -24,8 +25,9 @@
 
 const DYNAMIC = 'dynamic';
 
-final TypeName NO_RETURN_TYPE = new TypeName(
-    new SimpleIdentifier(new StringToken(TokenType.IDENTIFIER, '', 0)), null);
+final TypeName NO_RETURN_TYPE = astFactory.typeName(
+    astFactory.simpleIdentifier(new StringToken(TokenType.IDENTIFIER, '', 0)),
+    null);
 
 /**
 * Create a new protocol Element for inclusion in a completion suggestion.
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/local_constructor_contributor.dart b/pkg/analysis_server/lib/src/services/completion/dart/local_constructor_contributor.dart
index 8778f6c..cef91de 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/local_constructor_contributor.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/local_constructor_contributor.dart
@@ -16,6 +16,7 @@
 import 'package:analysis_server/src/services/completion/dart/optype.dart';
 import 'package:analysis_server/src/services/completion/dart/suggestion_builder.dart';
 import 'package:analyzer/dart/ast/ast.dart';
+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/src/dart/ast/token.dart';
@@ -26,8 +27,9 @@
 
 const DYNAMIC = 'dynamic';
 
-final TypeName NO_RETURN_TYPE = new TypeName(
-    new SimpleIdentifier(new StringToken(TokenType.IDENTIFIER, '', 0)), null);
+final TypeName NO_RETURN_TYPE = astFactory.typeName(
+    astFactory.simpleIdentifier(new StringToken(TokenType.IDENTIFIER, '', 0)),
+    null);
 
 /**
 * Create a new protocol Element for inclusion in a completion suggestion.
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/local_declaration_visitor.dart b/pkg/analysis_server/lib/src/services/completion/dart/local_declaration_visitor.dart
index f0c2b3a..adf26c7 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/local_declaration_visitor.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/local_declaration_visitor.dart
@@ -5,6 +5,7 @@
 library services.completion.dart.local.declaration.visitor;
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/src/dart/ast/token.dart';
@@ -15,8 +16,8 @@
  * which catches the exception thrown by [finished()].
  */
 abstract class LocalDeclarationVisitor extends GeneralizingAstVisitor {
-  static final TypeName STACKTRACE_TYPE = new TypeName(
-      new SimpleIdentifier(
+  static final TypeName STACKTRACE_TYPE = astFactory.typeName(
+      astFactory.simpleIdentifier(
           new StringToken(TokenType.IDENTIFIER, 'StackTrace', 0)),
       null);
 
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/local_reference_contributor.dart b/pkg/analysis_server/lib/src/services/completion/dart/local_reference_contributor.dart
index 70b2b44..01298f8 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/local_reference_contributor.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/local_reference_contributor.dart
@@ -17,6 +17,7 @@
 import 'package:analysis_server/src/services/correction/strings.dart';
 import 'package:analysis_server/src/utilities/documentation.dart';
 import 'package:analyzer/dart/ast/ast.dart';
+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/type.dart';
@@ -29,8 +30,9 @@
 
 const DYNAMIC = 'dynamic';
 
-final TypeName NO_RETURN_TYPE = new TypeName(
-    new SimpleIdentifier(new StringToken(TokenType.IDENTIFIER, '', 0)), null);
+final TypeName NO_RETURN_TYPE = astFactory.typeName(
+    astFactory.simpleIdentifier(new StringToken(TokenType.IDENTIFIER, '', 0)),
+    null);
 
 /**
 * Create a new protocol Element for inclusion in a completion suggestion.
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 9899681..73a4bee 100644
--- a/pkg/analysis_server/lib/src/services/correction/assist_internal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/assist_internal.dart
@@ -233,7 +233,7 @@
     DartType type = declaredIdentifier.identifier.bestType;
     if (type is InterfaceType || type is FunctionType) {
       _configureTargetLocation(node);
-      Set<LibraryElement> librariesToImport = new Set<LibraryElement>();
+      Set<Source> librariesToImport = new Set<Source>();
       typeSource = utils.getTypeSource(type, librariesToImport);
       addLibraryImports(change, unitLibraryElement, librariesToImport);
     } else {
@@ -285,7 +285,7 @@
     String typeSource;
     {
       _configureTargetLocation(node);
-      Set<LibraryElement> librariesToImport = new Set<LibraryElement>();
+      Set<Source> librariesToImport = new Set<Source>();
       typeSource = utils.getTypeSource(type, librariesToImport);
       addLibraryImports(change, unitLibraryElement, librariesToImport);
     }
@@ -337,7 +337,7 @@
     String typeSource;
     if (type is InterfaceType || type is FunctionType) {
       _configureTargetLocation(node);
-      Set<LibraryElement> librariesToImport = new Set<LibraryElement>();
+      Set<Source> librariesToImport = new Set<Source>();
       typeSource = utils.getTypeSource(type, librariesToImport);
       addLibraryImports(change, unitLibraryElement, librariesToImport);
     } else {
@@ -1002,7 +1002,7 @@
       String name = (node as SimpleIdentifier).name;
       // prepare type
       DartType type = parameterElement.type;
-      Set<LibraryElement> librariesToImport = new Set<LibraryElement>();
+      Set<Source> librariesToImport = new Set<Source>();
       String typeCode = utils.getTypeSource(type, librariesToImport);
       // replace parameter
       if (type.isDynamic) {
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 76ee0e1..0b1c40e 100644
--- a/pkg/analysis_server/lib/src/services/correction/fix_internal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/fix_internal.dart
@@ -30,13 +30,16 @@
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/file_system/file_system.dart';
+import 'package:analyzer/src/dart/analysis/top_level_declaration.dart';
 import 'package:analyzer/src/dart/ast/token.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/member.dart';
 import 'package:analyzer/src/dart/element/type.dart';
+import 'package:analyzer/src/dart/resolver/inheritance_manager.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/generated/engine.dart';
+import 'package:analyzer/src/generated/error_verifier.dart';
 import 'package:analyzer/src/generated/java_core.dart';
 import 'package:analyzer/src/generated/parser.dart';
 import 'package:analyzer/src/generated/sdk.dart';
@@ -56,12 +59,12 @@
  * Clients may not extend, implement or mix-in this class.
  */
 class DartFixContextImpl extends FixContextImpl implements DartFixContext {
-  /**
-   * The [CompilationUnit] to compute fixes in.
-   */
+  final GetTopLevelDeclarations getTopLevelDeclarations;
   final CompilationUnit unit;
 
-  DartFixContextImpl(FixContext fixContext, this.unit) : super.from(fixContext);
+  DartFixContextImpl(
+      FixContext fixContext, this.getTopLevelDeclarations, this.unit)
+      : super.from(fixContext);
 }
 
 /**
@@ -86,6 +89,7 @@
   static const int MAX_LEVENSHTEIN_DISTANCE = 3;
 
   ResourceProvider resourceProvider;
+  GetTopLevelDeclarations getTopLevelDeclarations;
   CompilationUnit unit;
   AnalysisError error;
   AnalysisContext context;
@@ -103,7 +107,7 @@
   final LinkedHashMap<String, LinkedEditGroup> linkedPositionGroups =
       new LinkedHashMap<String, LinkedEditGroup>();
   Position exitPosition = null;
-  Set<LibraryElement> librariesToImport = new Set<LibraryElement>();
+  Set<Source> librariesToImport = new Set<Source>();
 
   CorrectionUtils utils;
   int errorOffset;
@@ -115,6 +119,7 @@
 
   FixProcessor(DartFixContext dartContext) {
     resourceProvider = dartContext.resourceProvider;
+    getTopLevelDeclarations = dartContext.getTopLevelDeclarations;
     context = dartContext.analysisContext;
     // unit
     unit = dartContext.unit;
@@ -177,9 +182,9 @@
         if (name != null && name.staticElement == null) {
           node = name;
           if (annotation.arguments == null) {
-            _addFix_importLibrary_withTopLevelVariable();
+            await _addFix_importLibrary_withTopLevelVariable();
           } else {
-            _addFix_importLibrary_withType();
+            await _addFix_importLibrary_withType();
             _addFix_createClass();
             _addFix_undefinedClass_useSimilar();
           }
@@ -287,20 +292,13 @@
       _addFix_makeEnclosingClassAbstract();
       _addFix_createNoSuchMethod();
       // implement methods
-      // TODO(scheglov) Fix another way to get unimplemented methods.
-      // AnalysisErrorWithProperties does not work with the new analysis driver.
-      if (error is AnalysisErrorWithProperties) {
-        AnalysisErrorWithProperties errorWithProperties =
-            error as AnalysisErrorWithProperties;
-        List<ExecutableElement> missingOverrides = errorWithProperties
-            .getProperty(ErrorProperty.UNIMPLEMENTED_METHODS);
-        _addFix_createMissingOverrides(missingOverrides);
-      }
+      _addFix_createMissingOverrides();
     }
-    if (errorCode == StaticWarningCode.CAST_TO_NON_TYPE ||
+    if (errorCode == CompileTimeErrorCode.UNDEFINED_CLASS ||
+        errorCode == StaticWarningCode.CAST_TO_NON_TYPE ||
         errorCode == StaticWarningCode.TYPE_TEST_WITH_UNDEFINED_NAME ||
         errorCode == StaticWarningCode.UNDEFINED_CLASS) {
-      _addFix_importLibrary_withType();
+      await _addFix_importLibrary_withType();
       _addFix_createClass();
       _addFix_undefinedClass_useSimilar();
     }
@@ -319,8 +317,8 @@
       _addFix_createField();
       _addFix_createGetter();
       _addFix_createFunction_forFunctionType();
-      _addFix_importLibrary_withType();
-      _addFix_importLibrary_withTopLevelVariable();
+      await _addFix_importLibrary_withType();
+      await _addFix_importLibrary_withTopLevelVariable();
       _addFix_createLocalVariable();
     }
     if (errorCode == StaticWarningCode.UNDEFINED_IDENTIFIER_AWAIT) {
@@ -343,11 +341,11 @@
       _addFix_nonBoolCondition_addNotNull();
     }
     if (errorCode == StaticTypeWarningCode.NON_TYPE_AS_TYPE_ARGUMENT) {
-      _addFix_importLibrary_withType();
+      await _addFix_importLibrary_withType();
       _addFix_createClass();
     }
     if (errorCode == StaticTypeWarningCode.UNDEFINED_FUNCTION) {
-      _addFix_importLibrary_withFunction();
+      await _addFix_importLibrary_withFunction();
       _addFix_undefinedFunction_useSimilar();
       _addFix_undefinedFunction_create();
     }
@@ -359,7 +357,7 @@
     }
     if (errorCode == HintCode.UNDEFINED_METHOD ||
         errorCode == StaticTypeWarningCode.UNDEFINED_METHOD) {
-      _addFix_importLibrary_withFunction();
+      await _addFix_importLibrary_withFunction();
       _addFix_undefinedMethod_useSimilar();
       _addFix_undefinedMethod_create();
       _addFix_undefinedFunction_create();
@@ -495,9 +493,17 @@
           AstNode targetNode = targetElement.computeNode();
           if (targetNode is FunctionDeclaration) {
             FunctionExpression function = targetNode.functionExpression;
-            targetOffset = function.parameters.leftParenthesis.end;
+            Token paren = function.parameters.leftParenthesis;
+            if (paren == null) {
+              return;
+            }
+            targetOffset = paren.end;
           } else if (targetNode is MethodDeclaration) {
-            targetOffset = targetNode.parameters.leftParenthesis.end;
+            Token paren = targetNode.parameters.leftParenthesis;
+            if (paren == null) {
+              return;
+            }
+            targetOffset = paren.end;
           } else {
             return;
           }
@@ -1279,9 +1285,19 @@
     _addFix(DartFixKind.CREATE_LOCAL_VARIABLE, [name]);
   }
 
-  void _addFix_createMissingOverrides(List<ExecutableElement> elements) {
-    elements = elements.toList();
-    int numElements = elements.length;
+  void _addFix_createMissingOverrides() {
+    // prepare target
+    ClassDeclaration targetClass = node.parent as ClassDeclaration;
+    ClassElement targetClassElement = targetClass.element;
+    utils.targetClassElement = targetClassElement;
+    List<ExecutableElement> elements = ErrorVerifier
+        .computeMissingOverrides(
+            context.analysisOptions.strongMode,
+            context.typeProvider,
+            context.typeSystem,
+            new InheritanceManager(unitLibraryElement),
+            targetClassElement)
+        .toList();
     // sort by name, getters before setters
     elements.sort((Element a, Element b) {
       int names = compareStrings(a.displayName, b.displayName);
@@ -1293,9 +1309,6 @@
       }
       return 1;
     });
-    // prepare target
-    ClassDeclaration targetClass = node.parent as ClassDeclaration;
-    utils.targetClassElement = targetClass.element;
     // prepare SourceBuilder
     int insertOffset = targetClass.end - 1;
     SourceBuilder sb = new SourceBuilder(file, insertOffset);
@@ -1310,6 +1323,7 @@
 
     // merge getter/setter pairs into fields
     String prefix = utils.getIndent(1);
+    int numElements = elements.length;
     for (int i = 0; i < elements.length; i++) {
       ExecutableElement element = elements[i];
       if (element.kind == ElementKind.GETTER && i + 1 < elements.length) {
@@ -1451,14 +1465,14 @@
     _addFix(DartFixKind.REPLACE_RETURN_TYPE_FUTURE, []);
   }
 
-  void _addFix_importLibrary(FixKind kind, LibraryElement libraryElement) {
-    librariesToImport.add(libraryElement);
-    Source librarySource = libraryElement.source;
-    String libraryUri = getLibrarySourceUri(unitLibraryElement, librarySource);
+  void _addFix_importLibrary(FixKind kind, Source library) {
+    librariesToImport.add(library);
+    String libraryUri = getLibrarySourceUri(unitLibraryElement, library);
     _addFix(kind, [libraryUri], importsOnly: true);
   }
 
-  void _addFix_importLibrary_withElement(String name, ElementKind kind) {
+  Future<Null> _addFix_importLibrary_withElement(String name,
+      List<ElementKind> elementKinds, TopLevelDeclarationKind kind2) async {
     // ignore if private
     if (name.startsWith('_')) {
       return;
@@ -1476,7 +1490,7 @@
       if (element is PropertyAccessorElement) {
         element = (element as PropertyAccessorElement).variable;
       }
-      if (element.kind != kind) {
+      if (!elementKinds.contains(element.kind)) {
         continue;
       }
       // may be apply prefix
@@ -1538,42 +1552,31 @@
         if (element is PropertyAccessorElement) {
           element = (element as PropertyAccessorElement).variable;
         }
-        if (element.kind != kind) {
+        if (!elementKinds.contains(element.kind)) {
           continue;
         }
         // add import
-        _addFix_importLibrary(DartFixKind.IMPORT_LIBRARY_SDK, libraryElement);
+        _addFix_importLibrary(
+            DartFixKind.IMPORT_LIBRARY_SDK, libraryElement.source);
       }
     }
     // check project libraries
     {
-      List<Source> librarySources = context.librarySources;
-      for (Source librarySource in librarySources) {
-        // we don't need SDK libraries here
+      List<TopLevelDeclarationInSource> declarations =
+          await getTopLevelDeclarations(name);
+      for (TopLevelDeclarationInSource declaration in declarations) {
+        // Check the kind.
+        if (declaration.declaration.kind != kind2) {
+          continue;
+        }
+        // Check the source.
+        Source librarySource = declaration.source;
         if (librarySource.isInSystemLibrary) {
           continue;
         }
-        // maybe already imported
         if (alreadyImportedWithPrefix.contains(librarySource)) {
           continue;
         }
-        // prepare LibraryElement
-        LibraryElement libraryElement =
-            context.getResult(librarySource, LIBRARY_ELEMENT4);
-        if (libraryElement == null) {
-          continue;
-        }
-        // prepare exported Element
-        Element element = getExportedElement(libraryElement, name);
-        if (element == null) {
-          continue;
-        }
-        if (element is PropertyAccessorElement) {
-          element = (element as PropertyAccessorElement).variable;
-        }
-        if (element.kind != kind) {
-          continue;
-        }
         // Compute the fix kind.
         FixKind fixKind;
         if (resourceProvider.pathContext
@@ -1581,7 +1584,7 @@
             .contains('src')) {
           // Bad: non-API.
           fixKind = DartFixKind.IMPORT_LIBRARY_PROJECT3;
-        } else if (element.library != libraryElement) {
+        } else if (declaration.isExported) {
           // Ugly: exports.
           fixKind = DartFixKind.IMPORT_LIBRARY_PROJECT2;
         } else {
@@ -1589,34 +1592,39 @@
           fixKind = DartFixKind.IMPORT_LIBRARY_PROJECT1;
         }
         // Add the fix.
-        _addFix_importLibrary(fixKind, libraryElement);
+        _addFix_importLibrary(fixKind, librarySource);
       }
     }
   }
 
-  void _addFix_importLibrary_withFunction() {
+  Future<Null> _addFix_importLibrary_withFunction() async {
     if (node is SimpleIdentifier && node.parent is MethodInvocation) {
       MethodInvocation invocation = node.parent as MethodInvocation;
       if (invocation.realTarget == null && invocation.methodName == node) {
         String name = (node as SimpleIdentifier).name;
-        _addFix_importLibrary_withElement(name, ElementKind.FUNCTION);
+        await _addFix_importLibrary_withElement(name,
+            const [ElementKind.FUNCTION], TopLevelDeclarationKind.function);
       }
     }
   }
 
-  void _addFix_importLibrary_withTopLevelVariable() {
+  Future<Null> _addFix_importLibrary_withTopLevelVariable() async {
     if (node is SimpleIdentifier) {
       String name = (node as SimpleIdentifier).name;
-      _addFix_importLibrary_withElement(name, ElementKind.TOP_LEVEL_VARIABLE);
+      await _addFix_importLibrary_withElement(
+          name,
+          const [ElementKind.TOP_LEVEL_VARIABLE],
+          TopLevelDeclarationKind.variable);
     }
   }
 
-  void _addFix_importLibrary_withType() {
+  Future<Null> _addFix_importLibrary_withType() async {
     if (_mayBeTypeIdentifier(node)) {
       String typeName = (node as SimpleIdentifier).name;
-      _addFix_importLibrary_withElement(typeName, ElementKind.CLASS);
-      _addFix_importLibrary_withElement(
-          typeName, ElementKind.FUNCTION_TYPE_ALIAS);
+      await _addFix_importLibrary_withElement(
+          typeName,
+          const [ElementKind.CLASS, ElementKind.FUNCTION_TYPE_ALIAS],
+          TopLevelDeclarationKind.type);
     }
   }
 
@@ -2036,23 +2044,17 @@
       MethodInvocation invocation = node.parent as MethodInvocation;
       // prepare environment
       Element targetElement;
-      String prefix;
-      int insertOffset;
-      String sourcePrefix;
-      String sourceSuffix;
       bool staticModifier = false;
+
+      ClassDeclaration targetClassNode;
       Expression target = invocation.realTarget;
       if (target == null) {
         targetElement = unitElement;
         ClassMember enclosingMember =
             node.getAncestor((node) => node is ClassMember);
-        ClassDeclaration enclosingClass = enclosingMember.parent;
-        utils.targetClassElement = enclosingClass.element;
+        targetClassNode = enclosingMember.parent;
+        utils.targetClassElement = targetClassNode.element;
         staticModifier = _inStaticContext();
-        prefix = utils.getNodePrefix(enclosingMember);
-        insertOffset = enclosingMember.end;
-        sourcePrefix = '$eol$eol';
-        sourceSuffix = '';
       } else {
         // prepare target interface type
         DartType targetType = target.bestType;
@@ -2066,32 +2068,24 @@
         if (targetTypeNode is! ClassDeclaration) {
           return;
         }
-        ClassDeclaration targetClassNode = targetTypeNode;
+        targetClassNode = targetTypeNode;
         // maybe static
         if (target is Identifier) {
           staticModifier = target.bestElement.kind == ElementKind.CLASS;
         }
-        // prepare insert offset
-        prefix = '  ';
-        insertOffset = targetClassNode.end - 1;
-        if (targetClassNode.members.isEmpty) {
-          sourcePrefix = '';
-        } else {
-          sourcePrefix = eol;
-        }
-        sourceSuffix = eol;
         // use different utils
         CompilationUnitElement targetUnitElement =
             getCompilationUnitElement(targetClassElement);
         CompilationUnit targetUnit = getParsedUnit(targetUnitElement);
         utils = new CorrectionUtils(targetUnit);
       }
+      ClassMemberLocation targetLocation =
+          utils.prepareNewMethodLocation(targetClassNode);
       String targetFile = targetElement.source.fullName;
       // build method source
-      SourceBuilder sb = new SourceBuilder(targetFile, insertOffset);
+      SourceBuilder sb = new SourceBuilder(targetFile, targetLocation.offset);
       {
-        sb.append(sourcePrefix);
-        sb.append(prefix);
+        sb.append(targetLocation.prefix);
         // maybe "static"
         if (staticModifier) {
           sb.append('static ');
@@ -2108,8 +2102,8 @@
           sb.endPosition();
         }
         _addFix_undefinedMethod_create_parameters(sb, invocation.argumentList);
-        sb.append(') {$eol$prefix}');
-        sb.append(sourceSuffix);
+        sb.append(') {}');
+        sb.append(targetLocation.suffix);
       }
       // insert source
       _insertBuilder(sb, targetElement);
diff --git a/pkg/analysis_server/lib/src/services/correction/util.dart b/pkg/analysis_server/lib/src/services/correction/util.dart
index 82f2652..d5eeeb0 100644
--- a/pkg/analysis_server/lib/src/services/correction/util.dart
+++ b/pkg/analysis_server/lib/src/services/correction/util.dart
@@ -29,8 +29,8 @@
  * Adds edits to the given [change] that ensure that all the [libraries] are
  * imported into the given [targetLibrary].
  */
-void addLibraryImports(SourceChange change, LibraryElement targetLibrary,
-    Set<LibraryElement> libraries) {
+void addLibraryImports(
+    SourceChange change, LibraryElement targetLibrary, Set<Source> libraries) {
   CorrectionUtils libUtils;
   try {
     CompilationUnitElement unitElement = targetLibrary.definingCompilationUnit;
@@ -54,7 +54,7 @@
 
   // Prepare all URIs to import.
   List<String> uriList = libraries
-      .map((library) => getLibrarySourceUri(targetLibrary, library.source))
+      .map((library) => getLibrarySourceUri(targetLibrary, library))
       .toList();
   uriList.sort((a, b) => a.compareTo(b));
 
@@ -367,7 +367,7 @@
  * Computes the best URI to import [what] into [from].
  */
 String getLibrarySourceUri(LibraryElement from, Source what) {
-  String whatFile = what.fullName;
+  String whatPath = what.fullName;
   // check if an absolute URI (such as 'dart:' or 'package:')
   Uri whatUri = what.uri;
   String whatUriScheme = whatUri.scheme;
@@ -376,7 +376,7 @@
   }
   // compute a relative URI
   String fromFolder = dirname(from.source.fullName);
-  String relativeFile = relative(whatFile, from: fromFolder);
+  String relativeFile = relative(whatPath, from: fromFolder);
   return split(relativeFile).join('/');
 }
 
@@ -765,7 +765,7 @@
    * if can not be resolved, should be treated as the `dynamic` type.
    */
   String getExpressionTypeSource(
-      Expression expression, Set<LibraryElement> librariesToImport) {
+      Expression expression, Set<Source> librariesToImport) {
     if (expression == null) {
       return null;
     }
@@ -1054,7 +1054,7 @@
    * @return the source for the parameter with the given type and name.
    */
   String getParameterSource(
-      DartType type, String name, Set<LibraryElement> librariesToImport) {
+      DartType type, String name, Set<Source> librariesToImport) {
     // no type
     if (type == null || type.isDynamic) {
       return name;
@@ -1121,7 +1121,7 @@
    * Fills [librariesToImport] with [LibraryElement]s whose elements are
    * used by the generated source, but not imported.
    */
-  String getTypeSource(DartType type, Set<LibraryElement> librariesToImport,
+  String getTypeSource(DartType type, Set<Source> librariesToImport,
       {StringBuffer parametersBuffer}) {
     StringBuffer sb = new StringBuffer();
     // type parameter
@@ -1173,7 +1173,7 @@
           sb.write(".");
         }
       } else {
-        librariesToImport.add(library);
+        librariesToImport.add(library.source);
       }
     }
     // append simple name
@@ -1317,6 +1317,16 @@
             member is MethodDeclaration && member.isGetter);
   }
 
+  ClassMemberLocation prepareNewMethodLocation(
+      ClassDeclaration classDeclaration) {
+    return prepareNewClassMemberLocation(
+        classDeclaration,
+        (member) =>
+            member is FieldDeclaration ||
+            member is ConstructorDeclaration ||
+            member is MethodDeclaration);
+  }
+
   /**
    * Returns the source with indentation changed from [oldIndent] to
    * [newIndent], keeping indentation of lines relative to each other.
diff --git a/pkg/analysis_server/lib/src/services/refactoring/convert_method_to_getter.dart b/pkg/analysis_server/lib/src/services/refactoring/convert_method_to_getter.dart
index b742612..e8ef23c 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/convert_method_to_getter.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/convert_method_to_getter.dart
@@ -24,11 +24,13 @@
 class ConvertMethodToGetterRefactoringImpl extends RefactoringImpl
     implements ConvertMethodToGetterRefactoring {
   final SearchEngine searchEngine;
+  final GetResolvedUnit getResolvedUnit;
   final ExecutableElement element;
 
   SourceChange change;
 
-  ConvertMethodToGetterRefactoringImpl(this.searchEngine, this.element);
+  ConvertMethodToGetterRefactoringImpl(
+      this.searchEngine, this.getResolvedUnit, this.element);
 
   @override
   String get refactoringName => 'Convert Method To Getter';
@@ -114,7 +116,7 @@
     }
   }
 
-  Future _updateElementReferences(Element element) async {
+  Future<Null> _updateElementReferences(Element element) async {
     List<SearchMatch> matches = await searchEngine.searchReferences(element);
     List<SourceReference> references = getSourceReferences(matches);
     for (SourceReference reference in references) {
@@ -123,7 +125,7 @@
       // prepare invocation
       MethodInvocation invocation;
       {
-        CompilationUnit refUnit = refElement.unit;
+        CompilationUnit refUnit = await getResolvedUnit(refElement);
         AstNode refNode =
             new NodeLocator(refRange.offset).searchWithin(refUnit);
         invocation = refNode.getAncestor((node) => node is MethodInvocation);
diff --git a/pkg/analysis_server/lib/src/services/refactoring/extract_method.dart b/pkg/analysis_server/lib/src/services/refactoring/extract_method.dart
index 4c613cfd..107abf3 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/extract_method.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/extract_method.dart
@@ -81,7 +81,7 @@
   LibraryElement libraryElement;
   SourceRange selectionRange;
   CorrectionUtils utils;
-  Set<LibraryElement> librariesToImport = new Set<LibraryElement>();
+  Set<Source> librariesToImport = new Set<Source>();
 
   String returnType = '';
   String variableType;
diff --git a/pkg/analysis_server/lib/src/services/refactoring/inline_method.dart b/pkg/analysis_server/lib/src/services/refactoring/inline_method.dart
index 8a0322c..d1a8165 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/inline_method.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/inline_method.dart
@@ -191,18 +191,12 @@
 }
 
 /**
- * Completes with the resolved [CompilationUnit] that contains the [element].
- */
-typedef Future<CompilationUnit> GetResolvedUnitContainingElement(
-    Element element);
-
-/**
  * [InlineMethodRefactoring] implementation.
  */
 class InlineMethodRefactoringImpl extends RefactoringImpl
     implements InlineMethodRefactoring {
   final SearchEngine searchEngine;
-  final GetResolvedUnitContainingElement getResolvedUnit;
+  final GetResolvedUnit getResolvedUnit;
   final CompilationUnit unit;
   final int offset;
   CorrectionUtils utils;
diff --git a/pkg/analysis_server/lib/src/services/refactoring/refactoring.dart b/pkg/analysis_server/lib/src/services/refactoring/refactoring.dart
index 5cf982f..9c2da5d 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/refactoring.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/refactoring.dart
@@ -31,6 +31,11 @@
 import 'package:analyzer/src/generated/source.dart';
 
 /**
+ * Completes with the resolved [CompilationUnit] that contains the [element].
+ */
+typedef Future<CompilationUnit> GetResolvedUnit(Element element);
+
+/**
  * [Refactoring] to convert getters into normal [MethodDeclaration]s.
  */
 abstract class ConvertGetterToMethodRefactoring implements Refactoring {
@@ -52,9 +57,10 @@
    * Returns a new [ConvertMethodToGetterRefactoring] instance for converting
    * [element] and all the corresponding hierarchy elements.
    */
-  factory ConvertMethodToGetterRefactoring(
-      SearchEngine searchEngine, ExecutableElement element) {
-    return new ConvertMethodToGetterRefactoringImpl(searchEngine, element);
+  factory ConvertMethodToGetterRefactoring(SearchEngine searchEngine,
+      GetResolvedUnit getResolvedUnit, ExecutableElement element) {
+    return new ConvertMethodToGetterRefactoringImpl(
+        searchEngine, getResolvedUnit, element);
   }
 }
 
@@ -248,11 +254,8 @@
   /**
    * Returns a new [InlineMethodRefactoring] instance.
    */
-  factory InlineMethodRefactoring(
-      SearchEngine searchEngine,
-      GetResolvedUnitContainingElement getResolvedUnit,
-      CompilationUnit unit,
-      int offset) {
+  factory InlineMethodRefactoring(SearchEngine searchEngine,
+      GetResolvedUnit getResolvedUnit, CompilationUnit unit, int offset) {
     return new InlineMethodRefactoringImpl(
         searchEngine, getResolvedUnit, unit, offset);
   }
diff --git a/pkg/analysis_server/lib/src/services/search/search_engine_internal2.dart b/pkg/analysis_server/lib/src/services/search/search_engine_internal2.dart
index 72cd494..04dd6c5 100644
--- a/pkg/analysis_server/lib/src/services/search/search_engine_internal2.dart
+++ b/pkg/analysis_server/lib/src/services/search/search_engine_internal2.dart
@@ -48,8 +48,12 @@
 
   @override
   Future<List<SearchMatch>> searchSubtypes(ClassElement type) async {
-    // TODO(scheglov) implement
-    return [];
+    List<SearchResult> allResults = [];
+    for (AnalysisDriver driver in _drivers) {
+      List<SearchResult> results = await driver.search.subTypes(type);
+      allResults.addAll(results);
+    }
+    return allResults.map(_SearchMatch.forSearchResult).toList();
   }
 
   @override
diff --git a/pkg/analysis_server/lib/src/status/get_handler2.dart b/pkg/analysis_server/lib/src/status/get_handler2.dart
index 8bd958e..2541deb 100644
--- a/pkg/analysis_server/lib/src/status/get_handler2.dart
+++ b/pkg/analysis_server/lib/src/status/get_handler2.dart
@@ -383,8 +383,7 @@
       driver = analysisServer.driverMap[folder];
     }
 
-    // TODO(scheglov) Show priority files.
-//    List<String> priorityNames = <String>[];
+    List<String> priorityFiles = driver.priorityFiles;
     List<String> addedFiles = driver.addedFiles.toList();
     List<String> implicitFiles =
         driver.knownFiles.difference(driver.addedFiles).toList();
@@ -517,9 +516,8 @@
           }
         }
 
-        // TODO(scheglov) Show priority files.
-//        _writeFiles(
-//            buffer, 'Priority Files (${priorityNames.length})', priorityNames);
+        _writeFiles(
+            buffer, 'Priority Files (${priorityFiles.length})', priorityFiles);
         _writeFiles(buffer, 'Added Files (${addedFiles.length})', addedFiles);
         _writeFiles(
             buffer,
diff --git a/pkg/analysis_server/lib/src/utilities/change_builder_dart.dart b/pkg/analysis_server/lib/src/utilities/change_builder_dart.dart
index 94853ad..f438d257 100644
--- a/pkg/analysis_server/lib/src/utilities/change_builder_dart.dart
+++ b/pkg/analysis_server/lib/src/utilities/change_builder_dart.dart
@@ -458,10 +458,10 @@
   CorrectionUtils utils;
 
   /**
-   * A set containing the elements of the libraries that need to be imported in
+   * A set containing the sources of the libraries that need to be imported in
    * order to make visible the names used in generated code.
    */
-  Set<LibraryElement> librariesToImport = new Set<LibraryElement>();
+  Set<Source> librariesToImport = new Set<Source>();
 
   /**
    * Initialize a newly created builder to build a source file edit within the
diff --git a/pkg/analysis_server/test/analysis/notification_errors_test.dart b/pkg/analysis_server/test/analysis/notification_errors_test.dart
index 8ab02c3..6dfc501 100644
--- a/pkg/analysis_server/test/analysis/notification_errors_test.dart
+++ b/pkg/analysis_server/test/analysis/notification_errors_test.dart
@@ -6,7 +6,9 @@
 
 import 'package:analysis_server/plugin/protocol/protocol.dart';
 import 'package:analysis_server/src/constants.dart';
+import 'package:analysis_server/src/context_manager.dart';
 import 'package:analysis_server/src/domain_analysis.dart';
+import 'package:analyzer/src/dart/analysis/driver.dart';
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/services/lint.dart';
 import 'package:linter/src/linter.dart';
@@ -14,15 +16,17 @@
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../analysis_abstract.dart';
+import '../mocks.dart';
 
 main() {
   defineReflectiveSuite(() {
     defineReflectiveTests(NotificationErrorsTest);
+    defineReflectiveTests(NotificationErrorsTest_Driver);
   });
 }
 
 @reflectiveTest
-class NotificationErrorsTest extends AbstractAnalysisTest {
+class AbstractNotificationErrorsTest extends AbstractAnalysisTest {
   Map<String, List<AnalysisError>> filesErrors = {};
 
   void processNotification(Notification notification) {
@@ -47,6 +51,7 @@
 import 'does_not_exist.dart';
 ''');
     await waitForTasksFinished();
+    await pumpEventQueue();
     List<AnalysisError> errors = filesErrors[testFile];
     // Verify that we are generating only 1 error for the bad URI.
     // https://github.com/dart-lang/sdk/issues/23754
@@ -75,8 +80,16 @@
     handleSuccessfulRequest(request);
 
     await waitForTasksFinished();
-    AnalysisContext testContext = server.getContainingContext(testFile);
-    List<Linter> lints = getLints(testContext);
+    List<Linter> lints;
+    if (enableNewAnalysisDriver) {
+      AnalysisDriver testDriver = (server.contextManager as ContextManagerImpl)
+          .getContextInfoFor(resourceProvider.getFolder(projectPath))
+          .analysisDriver;
+      lints = testDriver.analysisOptions.lintRules;
+    } else {
+      AnalysisContext testContext = server.getContainingContext(testFile);
+      lints = getLints(testContext);
+    }
     // Registry should only contain single lint rule.
     expect(lints, hasLength(1));
     LintRule lint = lints.first as LintRule;
@@ -109,6 +122,7 @@
     createProject();
     addTestFile('library lib');
     await waitForTasksFinished();
+    await pumpEventQueue();
     List<AnalysisError> errors = filesErrors[testFile];
     expect(errors, hasLength(1));
     AnalysisError error = errors[0];
@@ -128,6 +142,7 @@
 }
 ''');
     await waitForTasksFinished();
+    await pumpEventQueue();
     List<AnalysisError> errors = filesErrors[testFile];
     expect(errors, hasLength(1));
     AnalysisError error = errors[0];
@@ -135,3 +150,16 @@
     expect(error.type, AnalysisErrorType.STATIC_WARNING);
   }
 }
+
+@reflectiveTest
+class NotificationErrorsTest extends AbstractNotificationErrorsTest {}
+
+@reflectiveTest
+class NotificationErrorsTest_Driver extends AbstractNotificationErrorsTest {
+  @override
+  void setUp() {
+    enableNewAnalysisDriver = true;
+    generateSummaryFiles = true;
+    super.setUp();
+  }
+}
diff --git a/pkg/analysis_server/test/analysis_abstract.dart b/pkg/analysis_server/test/analysis_abstract.dart
index d9f8984..43afb7b 100644
--- a/pkg/analysis_server/test/analysis_abstract.dart
+++ b/pkg/analysis_server/test/analysis_abstract.dart
@@ -46,6 +46,8 @@
  * An abstract base for all 'analysis' domain tests.
  */
 class AbstractAnalysisTest {
+  bool enableNewAnalysisDriver = false;
+  bool generateSummaryFiles = false;
   MockServerChannel serverChannel;
   MemoryResourceProvider resourceProvider;
   MockPackageMapProvider packageMapProvider;
@@ -126,18 +128,22 @@
     //
     // Create an SDK in the mock file system.
     //
-    new MockSdk(resourceProvider: resourceProvider);
+    new MockSdk(
+        generateSummaryFiles: generateSummaryFiles,
+        resourceProvider: resourceProvider);
     //
     // Create server
     //
+    AnalysisServerOptions options = new AnalysisServerOptions();
+    options.enableNewAnalysisDriver = enableNewAnalysisDriver;
     return new AnalysisServer(
         serverChannel,
         resourceProvider,
         packageMapProvider,
         index,
         serverPlugin,
-        new AnalysisServerOptions(),
-        new DartSdkManager(resourceProvider.convertPath('/'), false),
+        options,
+        new DartSdkManager(resourceProvider.convertPath('/'), true),
         InstrumentationService.NULL_SERVICE);
   }
 
diff --git a/pkg/analysis_server/test/analysis_server_test.dart b/pkg/analysis_server/test/analysis_server_test.dart
index a76d57b..b6a9475 100644
--- a/pkg/analysis_server/test/analysis_server_test.dart
+++ b/pkg/analysis_server/test/analysis_server_test.dart
@@ -121,20 +121,19 @@
     });
   }
 
-  void processRequiredPlugins() {
+  void processRequiredPlugins(ServerPlugin serverPlugin) {
     List<Plugin> plugins = <Plugin>[];
     plugins.addAll(AnalysisEngine.instance.requiredPlugins);
     plugins.add(AnalysisEngine.instance.optionsPlugin);
-    plugins.add(server.serverPlugin);
+    plugins.add(serverPlugin);
 
     ExtensionManager manager = new ExtensionManager();
     manager.processPlugins(plugins);
   }
 
   void setUp() {
-    ExtensionManager manager = new ExtensionManager();
-    ServerPlugin plugin = new ServerPlugin();
-    manager.processPlugins([plugin]);
+    ServerPlugin serverPlugin = new ServerPlugin();
+    processRequiredPlugins(serverPlugin);
     channel = new MockServerChannel();
     resourceProvider = new MemoryResourceProvider();
     // Create an SDK in the mock file system.
@@ -145,12 +144,11 @@
         resourceProvider,
         packageMapProvider,
         null,
-        plugin,
+        serverPlugin,
         new AnalysisServerOptions(),
         new DartSdkManager('/', false),
         InstrumentationService.NULL_SERVICE,
         rethrowExceptions: true);
-    processRequiredPlugins();
   }
 
   Future test_contextDisposed() {
diff --git a/pkg/analysis_server/test/context_manager_test.dart b/pkg/analysis_server/test/context_manager_test.dart
index 46a2d44..c95252b 100644
--- a/pkg/analysis_server/test/context_manager_test.dart
+++ b/pkg/analysis_server/test/context_manager_test.dart
@@ -2521,6 +2521,11 @@
     currentContext.applyChanges(changeSet);
   }
 
+  @override
+  void applyFileRemoved(AnalysisDriver driver, String file) {
+    throw new StateError('Unexpected invocation of applyFileRemoved');
+  }
+
   void assertContextFiles(String contextPath, List<String> expectedFiles) {
     var actualFiles = currentContextFilePaths[contextPath].keys;
     expect(actualFiles, unorderedEquals(expectedFiles));
diff --git a/pkg/analysis_server/test/domain_analysis_test.dart b/pkg/analysis_server/test/domain_analysis_test.dart
index 9230d23..0a8fd1c 100644
--- a/pkg/analysis_server/test/domain_analysis_test.dart
+++ b/pkg/analysis_server/test/domain_analysis_test.dart
@@ -13,8 +13,10 @@
 import 'package:analysis_server/src/plugin/server_plugin.dart';
 import 'package:analyzer/file_system/memory_file_system.dart';
 import 'package:analyzer/instrumentation/instrumentation.dart';
+import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/sdk.dart';
 import 'package:plugin/manager.dart';
+import 'package:plugin/plugin.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -33,12 +35,21 @@
   AnalysisServer server;
   AnalysisDomainHandler handler;
 
+  void processRequiredPlugins(ServerPlugin serverPlugin) {
+    List<Plugin> plugins = <Plugin>[];
+    plugins.addAll(AnalysisEngine.instance.requiredPlugins);
+    plugins.add(AnalysisEngine.instance.optionsPlugin);
+    plugins.add(serverPlugin);
+
+    ExtensionManager manager = new ExtensionManager();
+    manager.processPlugins(plugins);
+  }
+
   setUp(() {
     serverChannel = new MockServerChannel();
     resourceProvider = new MemoryResourceProvider();
-    ExtensionManager manager = new ExtensionManager();
     ServerPlugin serverPlugin = new ServerPlugin();
-    manager.processPlugins([serverPlugin]);
+    processRequiredPlugins(serverPlugin);
     // Create an SDK in the mock file system.
     new MockSdk(resourceProvider: resourceProvider);
     server = new AnalysisServer(
@@ -429,11 +440,10 @@
   String testCode;
 
   AnalysisTestHelper() {
+    ServerPlugin serverPlugin = new ServerPlugin();
+    processRequiredPlugins(serverPlugin);
     serverChannel = new MockServerChannel();
     resourceProvider = new MemoryResourceProvider();
-    ExtensionManager manager = new ExtensionManager();
-    ServerPlugin serverPlugin = new ServerPlugin();
-    manager.processPlugins([serverPlugin]);
     // Create an SDK in the mock file system.
     new MockSdk(resourceProvider: resourceProvider);
     server = new AnalysisServer(
@@ -597,6 +607,16 @@
     expect(response, isResponseSuccess('0'));
   }
 
+  void processRequiredPlugins(ServerPlugin serverPlugin) {
+    List<Plugin> plugins = <Plugin>[];
+    plugins.addAll(AnalysisEngine.instance.requiredPlugins);
+    plugins.add(AnalysisEngine.instance.optionsPlugin);
+    plugins.add(serverPlugin);
+
+    ExtensionManager manager = new ExtensionManager();
+    manager.processPlugins(plugins);
+  }
+
   /**
    * Send an `updateContent` request for [testFile].
    */
diff --git a/pkg/analysis_server/test/domain_diagnostic_test.dart b/pkg/analysis_server/test/domain_diagnostic_test.dart
index 78080e8..d24dea7 100644
--- a/pkg/analysis_server/test/domain_diagnostic_test.dart
+++ b/pkg/analysis_server/test/domain_diagnostic_test.dart
@@ -24,21 +24,20 @@
   DiagnosticDomainHandler handler;
   MemoryResourceProvider resourceProvider;
 
-  setUp(() {
-    //
-    // Collect plugins
-    //
-    ServerPlugin serverPlugin = new ServerPlugin();
+  void processRequiredPlugins(ServerPlugin serverPlugin) {
     List<Plugin> plugins = <Plugin>[];
     plugins.addAll(AnalysisEngine.instance.requiredPlugins);
     plugins.add(AnalysisEngine.instance.commandLinePlugin);
     plugins.add(AnalysisEngine.instance.optionsPlugin);
     plugins.add(serverPlugin);
-    //
-    // Process plugins
-    //
+
     ExtensionManager manager = new ExtensionManager();
     manager.processPlugins(plugins);
+  }
+
+  setUp(() {
+    ServerPlugin serverPlugin = new ServerPlugin();
+    processRequiredPlugins(serverPlugin);
     //
     // Create the server
     //
diff --git a/pkg/analysis_server/test/mock_sdk.dart b/pkg/analysis_server/test/mock_sdk.dart
index acb2095..3286a09 100644
--- a/pkg/analysis_server/test/mock_sdk.dart
+++ b/pkg/analysis_server/test/mock_sdk.dart
@@ -269,13 +269,24 @@
    */
   PackageBundle _bundle;
 
-  MockSdk({resource.ResourceProvider resourceProvider})
+  MockSdk(
+      {bool generateSummaryFiles: false,
+      resource.ResourceProvider resourceProvider})
       : provider = resourceProvider ?? new resource.MemoryResourceProvider() {
     LIBRARIES.forEach((SdkLibrary library) {
       provider.newFile(library.path, (library as MockSdkLibrary).content);
     });
-    provider.newFile('/lib/_internal/sdk_library_metadata/lib/libraries.dart',
+    provider.newFile(
+        provider.convertPath(
+            '/lib/_internal/sdk_library_metadata/lib/libraries.dart'),
         librariesContent);
+    if (generateSummaryFiles) {
+      List<int> bytes = _computeLinkedBundleBytes();
+      provider.newFileWithBytes(
+          provider.convertPath('/lib/_internal/spec.sum'), bytes);
+      provider.newFileWithBytes(
+          provider.convertPath('/lib/_internal/strong.sum'), bytes);
+    }
   }
 
   @override
@@ -341,12 +352,14 @@
   @override
   PackageBundle getLinkedBundle() {
     if (_bundle == null) {
-      List<Source> librarySources = sdkLibraries
-          .map((SdkLibrary library) => mapDartUri(library.shortName))
-          .toList();
-      List<int> bytes = new SummaryBuilder(
-              librarySources, context, context.analysisOptions.strongMode)
-          .build();
+      resource.File summaryFile =
+          provider.getFile(provider.convertPath('/lib/_internal/spec.sum'));
+      List<int> bytes;
+      if (summaryFile.exists) {
+        bytes = summaryFile.readAsBytesSync();
+      } else {
+        bytes = _computeLinkedBundleBytes();
+      }
       _bundle = new PackageBundle.fromBuffer(bytes);
     }
     return _bundle;
@@ -383,6 +396,18 @@
     // table above.
     return null;
   }
+
+  /**
+   * Compute the bytes of the linked bundle associated with this SDK.
+   */
+  List<int> _computeLinkedBundleBytes() {
+    List<Source> librarySources = sdkLibraries
+        .map((SdkLibrary library) => mapDartUri(library.shortName))
+        .toList();
+    return new SummaryBuilder(
+            librarySources, context, context.analysisOptions.strongMode)
+        .build();
+  }
 }
 
 class MockSdkLibrary implements SdkLibrary {
diff --git a/pkg/analysis_server/test/services/correction/fix_test.dart b/pkg/analysis_server/test/services/correction/fix_test.dart
index dc65a97..1aa9b1c 100644
--- a/pkg/analysis_server/test/services/correction/fix_test.dart
+++ b/pkg/analysis_server/test/services/correction/fix_test.dart
@@ -7,7 +7,6 @@
 import 'dart:async';
 
 import 'package:analysis_server/plugin/edit/fix/fix_core.dart';
-import 'package:analysis_server/plugin/edit/fix/fix_dart.dart';
 import 'package:analysis_server/plugin/protocol/protocol.dart'
     hide AnalysisError;
 import 'package:analysis_server/src/services/correction/fix.dart';
@@ -142,10 +141,9 @@
    * Computes fixes for the given [error] in [testUnit].
    */
   Future<List<Fix>> _computeFixes(AnalysisError error) async {
-    DartFixContext dartContext = new DartFixContextImpl(
-        new FixContextImpl(provider, context, error), testUnit);
-    FixProcessor processor = new FixProcessor(dartContext);
-    return processor.compute();
+    FixContextImpl fixContext = new FixContextImpl(provider, context, error);
+    DefaultFixContributor contributor = new DefaultFixContributor();
+    return contributor.computeFixes(fixContext);
   }
 
   /**
@@ -3171,6 +3169,31 @@
 ''');
   }
 
+  test_importLibraryProject_withClass_constInstanceCreation() async {
+    addSource(
+        '/lib.dart',
+        '''
+class Test {
+  const Test();
+}
+''');
+    resolveTestUnit('''
+main() {
+  const Test();
+}
+''');
+    performAllAnalysisTasks();
+    await assertHasFix(
+        DartFixKind.IMPORT_LIBRARY_PROJECT1,
+        '''
+import 'lib.dart';
+
+main() {
+  const Test();
+}
+''');
+  }
+
   test_importLibraryProject_withClass_hasOtherLibraryWithPrefix() async {
     testFile = '/project/bin/test.dart';
     addSource(
@@ -4601,8 +4624,7 @@
 }
 
 class B {
-  void process(Map items) {
-  }
+  void process(Map items) {}
 }
 ''');
   }
@@ -4628,8 +4650,7 @@
 }
 
 class B {
-  dynamic compute() {
-  }
+  dynamic compute() {}
 }
 ''');
   }
@@ -4644,8 +4665,7 @@
   }
 }
 
-class B {
-}
+class B {}
 ''');
     await assertHasFix(
         DartFixKind.CREATE_METHOD,
@@ -4659,8 +4679,7 @@
 }
 
 class B {
-  void process(List<int> items) {
-  }
+  void process(List<int> items) {}
 }
 ''');
   }
@@ -4683,8 +4702,26 @@
     process(items);
   }
 
-  void process(List<T> items) {
+  void process(List<T> items) {}
+}
+''');
   }
+
+  test_undefinedMethod_createQualified_emptyClassBody() async {
+    resolveTestUnit('''
+class A {}
+main() {
+  A.myUndefinedMethod();
+}
+''');
+    await assertHasFix(
+        DartFixKind.CREATE_METHOD,
+        '''
+class A {
+  static void myUndefinedMethod() {}
+}
+main() {
+  A.myUndefinedMethod();
 }
 ''');
   }
@@ -4701,8 +4738,7 @@
         DartFixKind.CREATE_METHOD,
         '''
 class A {
-  static void myUndefinedMethod() {
-  }
+  static void myUndefinedMethod() {}
 }
 main() {
   A.myUndefinedMethod();
@@ -4725,8 +4761,7 @@
 class A {
   foo() {}
 
-  static void myUndefinedMethod() {
-  }
+  static void myUndefinedMethod() {}
 }
 main() {
   A.myUndefinedMethod();
@@ -4746,8 +4781,7 @@
         DartFixKind.CREATE_METHOD,
         '''
 class A {
-  void myUndefinedMethod() {
-  }
+  void myUndefinedMethod() {}
 }
 main(A a) {
   a.myUndefinedMethod();
@@ -4797,8 +4831,7 @@
     bar(c1.x, c2.x);
   }
 
-  void bar(int x, int x2) {
-  }
+  void bar(int x, int x2) {}
 }''');
   }
 
@@ -4818,8 +4851,7 @@
     myUndefinedMethod(0, 1.0, '3');
   }
 
-  void myUndefinedMethod(int i, double d, String s) {
-  }
+  void myUndefinedMethod(int i, double d, String s) {}
 }
 ''');
     // linked positions
@@ -4864,8 +4896,7 @@
     myUndefinedMethod(0, bbb: 1.0, ccc: '2');
   }
 
-  void myUndefinedMethod(int i, {double bbb, String ccc}) {
-  }
+  void myUndefinedMethod(int i, {double bbb, String ccc}) {}
 }
 ''');
     // linked positions
@@ -4908,8 +4939,7 @@
     int v = myUndefinedMethod();
   }
 
-  int myUndefinedMethod() {
-  }
+  int myUndefinedMethod() {}
 }
 ''');
     // linked positions
@@ -4930,8 +4960,7 @@
 class A {
   static var f = myUndefinedMethod();
 
-  static myUndefinedMethod() {
-  }
+  static myUndefinedMethod() {}
 }
 ''');
   }
@@ -4952,8 +4981,7 @@
     myUndefinedMethod();
   }
 
-  static void myUndefinedMethod() {
-  }
+  static void myUndefinedMethod() {}
 }
 ''');
   }
@@ -4971,8 +4999,7 @@
         DartFixKind.CREATE_METHOD,
         '''
 class A {
-  void myUndefinedMethod() {
-  }
+  void myUndefinedMethod() {}
 }
 main() {
   var a = new A();
@@ -5018,8 +5045,7 @@
 import 'test3.dart' as bbb;
 export 'test3.dart';
 class D {
-  void foo(bbb.E e) {
-  }
+  void foo(bbb.E e) {}
 }
 ''');
   }
@@ -5052,8 +5078,7 @@
         r'''
 library test2;
 class D {
-  void foo(E e) {
-  }
+  void foo(E e) {}
 }
 class E {}
 ''');
diff --git a/pkg/analysis_server/test/services/correction/util_test.dart b/pkg/analysis_server/test/services/correction/util_test.dart
index 2eb68bb..ee3089e 100644
--- a/pkg/analysis_server/test/services/correction/util_test.dart
+++ b/pkg/analysis_server/test/services/correction/util_test.dart
@@ -7,7 +7,6 @@
 import 'package:analysis_server/plugin/protocol/protocol.dart';
 import 'package:analysis_server/src/services/correction/strings.dart';
 import 'package:analysis_server/src/services/correction/util.dart';
-import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
@@ -27,9 +26,9 @@
 import 'dart:async';
 import 'dart:math';
 ''');
-    LibraryElement newLibrary = _getDartLibrary('dart:collection');
+    Source newLibrary = _getDartSource('dart:collection');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary],
+        <Source>[newLibrary],
         '''
 import 'dart:async';
 import 'dart:collection';
@@ -42,9 +41,9 @@
 import 'dart:collection';
 import 'dart:math';
 ''');
-    LibraryElement newLibrary = _getDartLibrary('dart:async');
+    Source newLibrary = _getDartSource('dart:async');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary],
+        <Source>[newLibrary],
         '''
 import 'dart:async';
 import 'dart:collection';
@@ -57,9 +56,9 @@
 import 'dart:async';
 import 'dart:collection';
 ''');
-    LibraryElement newLibrary = _getDartLibrary('dart:math');
+    Source newLibrary = _getDartSource('dart:math');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary],
+        <Source>[newLibrary],
         '''
 import 'dart:async';
 import 'dart:collection';
@@ -72,10 +71,10 @@
 import 'dart:collection';
 import 'dart:math';
 ''');
-    LibraryElement newLibrary1 = _getDartLibrary('dart:async');
-    LibraryElement newLibrary2 = _getDartLibrary('dart:html');
+    Source newLibrary1 = _getDartSource('dart:async');
+    Source newLibrary2 = _getDartSource('dart:html');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 import 'dart:async';
 import 'dart:collection';
@@ -89,10 +88,10 @@
 import 'dart:html';
 import 'dart:math';
 ''');
-    LibraryElement newLibrary1 = _getDartLibrary('dart:async');
-    LibraryElement newLibrary2 = _getDartLibrary('dart:collection');
+    Source newLibrary1 = _getDartSource('dart:async');
+    Source newLibrary2 = _getDartSource('dart:collection');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 import 'dart:async';
 import 'dart:collection';
@@ -106,10 +105,10 @@
 import 'dart:async';
 import 'dart:collection';
 ''');
-    LibraryElement newLibrary1 = _getDartLibrary('dart:html');
-    LibraryElement newLibrary2 = _getDartLibrary('dart:math');
+    Source newLibrary1 = _getDartSource('dart:html');
+    Source newLibrary2 = _getDartSource('dart:math');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 import 'dart:async';
 import 'dart:collection';
@@ -124,10 +123,10 @@
 
 class A {}
 ''');
-    LibraryElement newLibrary1 = _getDartLibrary('dart:math');
-    LibraryElement newLibrary2 = _getDartLibrary('dart:async');
+    Source newLibrary1 = _getDartSource('dart:math');
+    Source newLibrary2 = _getDartSource('dart:async');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 library test;
 
@@ -144,10 +143,10 @@
 
 class A {}
 ''');
-    LibraryElement newLibrary1 = _getDartLibrary('dart:math');
-    LibraryElement newLibrary2 = _getDartLibrary('dart:async');
+    Source newLibrary1 = _getDartSource('dart:math');
+    Source newLibrary2 = _getDartSource('dart:async');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 /// Comment.
 
@@ -164,10 +163,10 @@
 
 class A {}
 ''');
-    LibraryElement newLibrary1 = _getDartLibrary('dart:math');
-    LibraryElement newLibrary2 = _getDartLibrary('dart:async');
+    Source newLibrary1 = _getDartSource('dart:math');
+    Source newLibrary2 = _getDartSource('dart:async');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 #!/bin/dart
 
@@ -182,10 +181,10 @@
     resolveTestUnit('''
 class A {}
 ''');
-    LibraryElement newLibrary1 = _getDartLibrary('dart:math');
-    LibraryElement newLibrary2 = _getDartLibrary('dart:async');
+    Source newLibrary1 = _getDartSource('dart:math');
+    Source newLibrary2 = _getDartSource('dart:async');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 import 'dart:async';
 import 'dart:math';
@@ -200,10 +199,9 @@
 
 import 'package:aaa/aaa.dart';
 ''');
-    LibraryElement newLibrary =
-        _mockLibraryElement('/lib/bbb.dart', 'package:bbb/bbb.dart');
+    Source newLibrary = _getSource('/lib/bbb.dart', 'package:bbb/bbb.dart');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary],
+        <Source>[newLibrary],
         '''
 import 'dart:async';
 
@@ -218,10 +216,9 @@
 
 import 'package:bbb/bbb.dart';
 ''');
-    LibraryElement newLibrary =
-        _mockLibraryElement('/lib/aaa.dart', 'package:aaa/aaa.dart');
+    Source newLibrary = _getSource('/lib/aaa.dart', 'package:aaa/aaa.dart');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary],
+        <Source>[newLibrary],
         '''
 import 'dart:async';
 
@@ -235,12 +232,10 @@
 import 'package:aaa/aaa.dart';
 import 'package:ddd/ddd.dart';
 ''');
-    LibraryElement newLibrary1 =
-        _mockLibraryElement('/lib/bbb.dart', 'package:bbb/bbb.dart');
-    LibraryElement newLibrary2 =
-        _mockLibraryElement('/lib/ccc.dart', 'package:ccc/ccc.dart');
+    Source newLibrary1 = _getSource('/lib/bbb.dart', 'package:bbb/bbb.dart');
+    Source newLibrary2 = _getSource('/lib/ccc.dart', 'package:ccc/ccc.dart');
     _assertAddLibraryImport(
-        <LibraryElement>[newLibrary1, newLibrary2],
+        <Source>[newLibrary1, newLibrary2],
         '''
 import 'package:aaa/aaa.dart';
 import 'package:bbb/bbb.dart';
@@ -249,8 +244,7 @@
 ''');
   }
 
-  void _assertAddLibraryImport(
-      List<LibraryElement> newLibraries, String expectedCode) {
+  void _assertAddLibraryImport(List<Source> newLibraries, String expectedCode) {
     SourceChange change = new SourceChange('');
     addLibraryImports(change, testLibraryElement, newLibraries.toSet());
     SourceFileEdit testEdit = change.getFileEdit(testFile);
@@ -259,27 +253,16 @@
     expect(resultCode, expectedCode);
   }
 
-  LibraryElement _getDartLibrary(String uri) {
+  Source _getDartSource(String uri) {
     String path = removeStart(uri, 'dart:');
-    Source newSource = new _SourceMock('/sdk/lib/$path.dart', Uri.parse(uri));
-    return new _LibraryElementMock(newSource);
+    return new _SourceMock('/sdk/lib/$path.dart', Uri.parse(uri));
   }
 
-  LibraryElement _mockLibraryElement(String path, String uri) {
-    Source newSource = new _SourceMock(path, Uri.parse(uri));
-    return new _LibraryElementMock(newSource);
+  Source _getSource(String path, String uri) {
+    return new _SourceMock(path, Uri.parse(uri));
   }
 }
 
-class _LibraryElementMock implements LibraryElement {
-  @override
-  final Source source;
-
-  _LibraryElementMock(this.source);
-
-  noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
-}
-
 class _SourceMock implements Source {
   @override
   final String fullName;
diff --git a/pkg/analysis_server/test/services/refactoring/abstract_refactoring.dart b/pkg/analysis_server/test/services/refactoring/abstract_refactoring.dart
index 2ee99d1..793a1ec 100644
--- a/pkg/analysis_server/test/services/refactoring/abstract_refactoring.dart
+++ b/pkg/analysis_server/test/services/refactoring/abstract_refactoring.dart
@@ -6,12 +6,19 @@
 
 import 'dart:async';
 
-import 'package:analysis_server/plugin/protocol/protocol.dart';
+import 'package:analysis_server/plugin/protocol/protocol.dart'
+    show
+        RefactoringProblem,
+        RefactoringProblemSeverity,
+        SourceChange,
+        SourceEdit,
+        SourceFileEdit;
 import 'package:analysis_server/src/services/correction/status.dart';
 import 'package:analysis_server/src/services/index/index.dart';
 import 'package:analysis_server/src/services/refactoring/refactoring.dart';
 import 'package:analysis_server/src/services/search/search_engine_internal.dart';
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/element/element.dart' show Element;
 import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:test/test.dart';
@@ -145,6 +152,14 @@
     expect(actualCode, expectedCode);
   }
 
+  /**
+   * Completes with a fully resolved unit that contains the [element].
+   */
+  Future<CompilationUnit> getResolvedUnitWithElement(Element element) async {
+    return element.context
+        .resolveCompilationUnit(element.source, element.library);
+  }
+
   void indexTestUnit(String code) {
     resolveTestUnit(code);
     index.indexUnit(testUnit);
diff --git a/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart b/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart
index accf182..30bbb5b 100644
--- a/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart
+++ b/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart
@@ -6,7 +6,8 @@
 
 import 'dart:async';
 
-import 'package:analysis_server/plugin/protocol/protocol.dart' hide ElementKind;
+import 'package:analysis_server/plugin/protocol/protocol.dart'
+    show RefactoringProblemSeverity, SourceChange;
 import 'package:analysis_server/src/services/correction/status.dart';
 import 'package:analysis_server/src/services/refactoring/refactoring.dart';
 import 'package:analyzer/dart/element/element.dart';
@@ -205,7 +206,8 @@
   }
 
   void _createRefactoringForElement(ExecutableElement element) {
-    refactoring = new ConvertMethodToGetterRefactoring(searchEngine, element);
+    refactoring = new ConvertMethodToGetterRefactoring(
+        searchEngine, getResolvedUnitWithElement, element);
   }
 
   void _createRefactoringForString(String search) {
diff --git a/pkg/analysis_server/test/services/refactoring/inline_method_test.dart b/pkg/analysis_server/test/services/refactoring/inline_method_test.dart
index c629f93..bf8f481 100644
--- a/pkg/analysis_server/test/services/refactoring/inline_method_test.dart
+++ b/pkg/analysis_server/test/services/refactoring/inline_method_test.dart
@@ -1713,6 +1713,6 @@
   void _createRefactoring(String search) {
     int offset = findOffset(search);
     refactoring = new InlineMethodRefactoring(
-        searchEngine, (element) async => element.unit, testUnit, offset);
+        searchEngine, getResolvedUnitWithElement, testUnit, offset);
   }
 }
diff --git a/pkg/analysis_server/test/test_all.dart b/pkg/analysis_server/test/test_all.dart
index 50dbfaa..3e7b635 100644
--- a/pkg/analysis_server/test/test_all.dart
+++ b/pkg/analysis_server/test/test_all.dart
@@ -54,5 +54,5 @@
     socket_server_test.main();
     source_all.main();
     src_all.main();
-  }, name: 'analisys_server');
+  }, name: 'analysis_server');
 }
diff --git a/pkg/analyzer/CHANGELOG.md b/pkg/analyzer/CHANGELOG.md
index e7a9e48..8449bf0 100644
--- a/pkg/analyzer/CHANGELOG.md
+++ b/pkg/analyzer/CHANGELOG.md
@@ -2,6 +2,7 @@
 * Changed the API for creating BazelWorkspace.  It should now be constructed using BazelWorkspace.find().  Note that this might return `null` in the event that the given path is not part of a BazelWorkspace.
 * Added an AST structure to support asserts in constructor initializers (AssertInitializer).  AstVisitor classes must now implement visitAssertInitializer().
 * Changed the API for creating PartOfDirective.  It now accepts a StringLiteral URI, to accomodate "part of" declarations with a URI string rather than a library name.
+* Removed AST constructors.  AST nodes should now be created using `astFactory`, located in `package:analyzer/dart/ast/standard_ast_factory.dart`.
 
 ## 0.29.0-alpha.0
 * Removed `Element.docRange`.
diff --git a/pkg/analyzer/lib/dart/ast/ast.dart b/pkg/analyzer/lib/dart/ast/ast.dart
index c36925f..78b3c06 100644
--- a/pkg/analyzer/lib/dart/ast/ast.dart
+++ b/pkg/analyzer/lib/dart/ast/ast.dart
@@ -40,7 +40,6 @@
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/element/element.dart' show AuxiliaryElements;
 import 'package:analyzer/src/generated/java_engine.dart';
 import 'package:analyzer/src/generated/source.dart' show LineInfo, Source;
@@ -61,12 +60,6 @@
  */
 abstract class AdjacentStrings extends StringLiteral {
   /**
-   * Initialize a newly created list of adjacent strings. To be syntactically
-   * valid, the list of [strings] must contain at least two elements.
-   */
-  factory AdjacentStrings(List<StringLiteral> strings) = AdjacentStringsImpl;
-
-  /**
    * Return the strings that are implicitly concatenated.
    */
   NodeList<StringLiteral> get strings;
@@ -121,16 +114,6 @@
  */
 abstract class Annotation extends AstNode {
   /**
-   * Initialize a newly created annotation. Both the [period] and the
-   * [constructorName] can be `null` if the annotation is not referencing a
-   * named constructor. The [arguments] can be `null` if the annotation is not
-   * referencing a constructor.
-   */
-  factory Annotation(Token atSign, Identifier name, Token period,
-          SimpleIdentifier constructorName, ArgumentList arguments) =>
-      new AnnotationImpl(atSign, name, period, constructorName, arguments);
-
-  /**
    * Return the arguments to the constructor being invoked, or `null` if this
    * annotation is not the invocation of a constructor.
    */
@@ -224,13 +207,6 @@
  */
 abstract class ArgumentList extends AstNode {
   /**
-   * Initialize a newly created list of arguments. The list of [arguments] can
-   * be `null` if there are no arguments.
-   */
-  factory ArgumentList(Token leftParenthesis, List<Expression> arguments,
-      Token rightParenthesis) = ArgumentListImpl;
-
-  /**
    * Return the expressions producing the values of the arguments. Although the
    * language requires that positional arguments appear before named arguments,
    * this class allows them to be intermixed.
@@ -284,13 +260,6 @@
  */
 abstract class AsExpression extends Expression {
   /**
-   * Initialize a newly created as expression.
-   */
-  factory AsExpression(
-          Expression expression, Token asOperator, TypeName type) =>
-      new AsExpressionImpl(expression, asOperator, type);
-
-  /**
    * Return the 'as' operator.
    */
   Token get asOperator;
@@ -330,21 +299,7 @@
  *
  * Clients may not extend, implement or mix-in this class.
  */
-abstract class AssertInitializer implements Assertion, ConstructorInitializer {
-  /**
-   * Initialize a newly created assert initializer. The [comma] and [message]
-   * can be `null` if there is no message.
-   */
-  factory AssertInitializer(
-          Token assertKeyword,
-          Token leftParenthesis,
-          Expression condition,
-          Token comma,
-          Expression message,
-          Token rightParenthesis) =>
-      new AssertInitializerImpl(assertKeyword, leftParenthesis, condition,
-          comma, message, rightParenthesis);
-}
+abstract class AssertInitializer implements Assertion, ConstructorInitializer {}
 
 /**
  * An assertion, either in a block or in the initializer list of a constructor.
@@ -428,21 +383,6 @@
  */
 abstract class AssertStatement implements Assertion, Statement {
   /**
-   * Initialize a newly created assert statement. The [comma] and [message] can
-   * be `null` if there is no message.
-   */
-  factory AssertStatement(
-          Token assertKeyword,
-          Token leftParenthesis,
-          Expression condition,
-          Token comma,
-          Expression message,
-          Token rightParenthesis,
-          Token semicolon) =>
-      new AssertStatementImpl(assertKeyword, leftParenthesis, condition, comma,
-          message, rightParenthesis, semicolon);
-
-  /**
    * Return the semicolon terminating the statement.
    */
   Token get semicolon;
@@ -464,13 +404,6 @@
 abstract class AssignmentExpression extends Expression
     implements MethodReferenceExpression {
   /**
-   * Initialize a newly created assignment expression.
-   */
-  factory AssignmentExpression(
-          Expression leftHandSide, Token operator, Expression rightHandSide) =>
-      new AssignmentExpressionImpl(leftHandSide, operator, rightHandSide);
-
-  /**
    * Return the expression used to compute the left hand side.
    */
   Expression get leftHandSide;
@@ -856,12 +789,6 @@
  */
 abstract class AwaitExpression extends Expression {
   /**
-   * Initialize a newly created await expression.
-   */
-  factory AwaitExpression(Token awaitKeyword, Expression expression) =>
-      new AwaitExpressionImpl(awaitKeyword, expression);
-
-  /**
    * Return the 'await' keyword.
    */
   Token get awaitKeyword;
@@ -893,13 +820,6 @@
 abstract class BinaryExpression extends Expression
     implements MethodReferenceExpression {
   /**
-   * Initialize a newly created binary expression.
-   */
-  factory BinaryExpression(
-          Expression leftOperand, Token operator, Expression rightOperand) =>
-      new BinaryExpressionImpl(leftOperand, operator, rightOperand);
-
-  /**
    * Return the expression used to compute the left operand.
    */
   Expression get leftOperand;
@@ -942,13 +862,6 @@
  */
 abstract class Block extends Statement {
   /**
-   * Initialize a newly created block of code.
-   */
-  factory Block(
-          Token leftBracket, List<Statement> statements, Token rightBracket) =>
-      new BlockImpl(leftBracket, statements, rightBracket);
-
-  /**
    * Return the left curly bracket.
    */
   Token get leftBracket;
@@ -984,15 +897,6 @@
  */
 abstract class BlockFunctionBody extends FunctionBody {
   /**
-   * Initialize a newly created function body consisting of a block of
-   * statements. The [keyword] can be `null` if there is no keyword specified
-   * for the block. The [star] can be `null` if there is no star following the
-   * keyword (and must be `null` if there is no keyword).
-   */
-  factory BlockFunctionBody(Token keyword, Token star, Block block) =>
-      new BlockFunctionBodyImpl(keyword, star, block);
-
-  /**
    * Return the block representing the body of the function.
    */
   Block get block;
@@ -1023,11 +927,6 @@
  */
 abstract class BooleanLiteral extends Literal {
   /**
-   * Initialize a newly created boolean literal.
-   */
-  factory BooleanLiteral(Token literal, bool value) = BooleanLiteralImpl;
-
-  /**
    * Return the token representing the literal.
    */
   Token get literal;
@@ -1053,14 +952,6 @@
  */
 abstract class BreakStatement extends Statement {
   /**
-   * Initialize a newly created break statement. The [label] can be `null` if
-   * there is no label associated with the statement.
-   */
-  factory BreakStatement(
-          Token breakKeyword, SimpleIdentifier label, Token semicolon) =>
-      new BreakStatementImpl(breakKeyword, label, semicolon);
-
-  /**
    * Return the token representing the 'break' keyword.
    */
   Token get breakKeyword;
@@ -1129,14 +1020,6 @@
  */
 abstract class CascadeExpression extends Expression {
   /**
-   * Initialize a newly created cascade expression. The list of
-   * [cascadeSections] must contain at least one element.
-   */
-  factory CascadeExpression(
-          Expression target, List<Expression> cascadeSections) =>
-      new CascadeExpressionImpl(target, cascadeSections);
-
-  /**
    * Return the cascade sections sharing the common target.
    */
   NodeList<Expression> get cascadeSections;
@@ -1166,33 +1049,6 @@
  */
 abstract class CatchClause extends AstNode {
   /**
-   * Initialize a newly created catch clause. The [onKeyword] and
-   * [exceptionType] can be `null` if the clause will catch all exceptions. The
-   * [comma] and [stackTraceParameter] can be `null` if the stack trace
-   * parameter is not defined.
-   */
-  factory CatchClause(
-          Token onKeyword,
-          TypeName exceptionType,
-          Token catchKeyword,
-          Token leftParenthesis,
-          SimpleIdentifier exceptionParameter,
-          Token comma,
-          SimpleIdentifier stackTraceParameter,
-          Token rightParenthesis,
-          Block body) =>
-      new CatchClauseImpl(
-          onKeyword,
-          exceptionType,
-          catchKeyword,
-          leftParenthesis,
-          exceptionParameter,
-          comma,
-          stackTraceParameter,
-          rightParenthesis,
-          body);
-
-  /**
    * Return the body of the catch block.
    */
   Block get body;
@@ -1306,43 +1162,6 @@
  */
 abstract class ClassDeclaration extends NamedCompilationUnitMember {
   /**
-   * Initialize a newly created class declaration. Either or both of the
-   * [comment] and [metadata] can be `null` if the class does not have the
-   * corresponding attribute. The [abstractKeyword] can be `null` if the class
-   * is not abstract. The [typeParameters] can be `null` if the class does not
-   * have any type parameters. Any or all of the [extendsClause], [withClause],
-   * and [implementsClause] can be `null` if the class does not have the
-   * corresponding clause. The list of [members] can be `null` if the class does
-   * not have any members.
-   */
-  factory ClassDeclaration(
-          Comment comment,
-          List<Annotation> metadata,
-          Token abstractKeyword,
-          Token classKeyword,
-          SimpleIdentifier name,
-          TypeParameterList typeParameters,
-          ExtendsClause extendsClause,
-          WithClause withClause,
-          ImplementsClause implementsClause,
-          Token leftBracket,
-          List<ClassMember> members,
-          Token rightBracket) =>
-      new ClassDeclarationImpl(
-          comment,
-          metadata,
-          abstractKeyword,
-          classKeyword,
-          name,
-          typeParameters,
-          extendsClause,
-          withClause,
-          implementsClause,
-          leftBracket,
-          members,
-          rightBracket);
-
-  /**
    * Return the 'abstract' keyword, or `null` if the keyword was absent.
    */
   Token get abstractKeyword;
@@ -1490,39 +1309,6 @@
  */
 abstract class ClassTypeAlias extends TypeAlias {
   /**
-   * Initialize a newly created class type alias. Either or both of the
-   * [comment] and [metadata] can be `null` if the class type alias does not
-   * have the corresponding attribute. The [typeParameters] can be `null` if the
-   * class does not have any type parameters. The [abstractKeyword] can be
-   * `null` if the class is not abstract. The [implementsClause] can be `null`
-   * if the class does not implement any interfaces.
-   */
-  factory ClassTypeAlias(
-          Comment comment,
-          List<Annotation> metadata,
-          Token keyword,
-          SimpleIdentifier name,
-          TypeParameterList typeParameters,
-          Token equals,
-          Token abstractKeyword,
-          TypeName superclass,
-          WithClause withClause,
-          ImplementsClause implementsClause,
-          Token semicolon) =>
-      new ClassTypeAliasImpl(
-          comment,
-          metadata,
-          keyword,
-          name,
-          typeParameters,
-          equals,
-          abstractKeyword,
-          superclass,
-          withClause,
-          implementsClause,
-          semicolon);
-
-  /**
    * Return the token for the 'abstract' keyword, or `null` if this is not
    * defining an abstract class.
    */
@@ -1638,15 +1424,6 @@
  */
 abstract class Comment extends AstNode {
   /**
-   * Initialize a newly created comment. The list of [tokens] must contain at
-   * least one token. The [type] is the type of the comment. The list of
-   * [references] can be empty if the comment does not contain any embedded
-   * references.
-   */
-  factory Comment(List<Token> tokens, CommentType type,
-      List<CommentReference> references) = CommentImpl;
-
-  /**
    * Return `true` if this is a block comment.
    */
   bool get isBlock;
@@ -1670,32 +1447,6 @@
    * Return the tokens representing the comment.
    */
   List<Token> get tokens;
-
-  /**
-   * Create a block comment consisting of the given [tokens].
-   */
-  static Comment createBlockComment(List<Token> tokens) =>
-      CommentImpl.createBlockComment(tokens);
-
-  /**
-   * Create a documentation comment consisting of the given [tokens].
-   */
-  static Comment createDocumentationComment(List<Token> tokens) =>
-      CommentImpl.createDocumentationComment(tokens);
-
-  /**
-   * Create a documentation comment consisting of the given [tokens] and having
-   * the given [references] embedded within it.
-   */
-  static Comment createDocumentationCommentWithReferences(
-          List<Token> tokens, List<CommentReference> references) =>
-      CommentImpl.createDocumentationCommentWithReferences(tokens, references);
-
-  /**
-   * Create an end-of-line comment consisting of the given [tokens].
-   */
-  static Comment createEndOfLineComment(List<Token> tokens) =>
-      CommentImpl.createEndOfLineComment(tokens);
 }
 
 /**
@@ -1708,13 +1459,6 @@
  */
 abstract class CommentReference extends AstNode {
   /**
-   * Initialize a newly created reference to a Dart element. The [newKeyword]
-   * can be `null` if the reference is not to a constructor.
-   */
-  factory CommentReference(Token newKeyword, Identifier identifier) =>
-      new CommentReferenceImpl(newKeyword, identifier);
-
-  /**
    * Return the identifier being referenced.
    */
   Identifier get identifier;
@@ -1763,22 +1507,6 @@
  */
 abstract class CompilationUnit extends AstNode {
   /**
-   * Initialize a newly created compilation unit to have the given directives
-   * and declarations. The [scriptTag] can be `null` if there is no script tag
-   * in the compilation unit. The list of [directives] can be `null` if there
-   * are no directives in the compilation unit. The list of [declarations] can
-   * be `null` if there are no declarations in the compilation unit.
-   */
-  factory CompilationUnit(
-          Token beginToken,
-          ScriptTag scriptTag,
-          List<Directive> directives,
-          List<CompilationUnitMember> declarations,
-          Token endToken) =>
-      new CompilationUnitImpl(
-          beginToken, scriptTag, directives, declarations, endToken);
-
-  /**
    * Set the first token included in this node's source range to the given
    * [token].
    */
@@ -1867,14 +1595,6 @@
  */
 abstract class ConditionalExpression extends Expression {
   /**
-   * Initialize a newly created conditional expression.
-   */
-  factory ConditionalExpression(Expression condition, Token question,
-          Expression thenExpression, Token colon, Expression elseExpression) =>
-      new ConditionalExpressionImpl(
-          condition, question, thenExpression, colon, elseExpression);
-
-  /**
    * Return the token used to separate the then expression from the else
    * expression.
    */
@@ -1950,20 +1670,6 @@
  */
 abstract class Configuration extends AstNode {
   /**
-   * Initialize a newly created configuration.
-   */
-  factory Configuration(
-          Token ifKeyword,
-          Token leftParenthesis,
-          DottedName name,
-          Token equalToken,
-          StringLiteral value,
-          Token rightParenthesis,
-          StringLiteral libraryUri) =>
-      new ConfigurationImpl(ifKeyword, leftParenthesis, name, equalToken, value,
-          rightParenthesis, libraryUri);
-
-  /**
    * Return the token for the equal operator, or `null` if the condition does
    * not include an equality test.
    */
@@ -2090,50 +1796,6 @@
  */
 abstract class ConstructorDeclaration extends ClassMember {
   /**
-   * Initialize a newly created constructor declaration. The [externalKeyword]
-   * can be `null` if the constructor is not external. Either or both of the
-   * [comment] and [metadata] can be `null` if the constructor does not have the
-   * corresponding attribute. The [constKeyword] can be `null` if the
-   * constructor cannot be used to create a constant. The [factoryKeyword] can
-   * be `null` if the constructor is not a factory. The [period] and [name] can
-   * both be `null` if the constructor is not a named constructor. The
-   * [separator] can be `null` if the constructor does not have any initializers
-   * and does not redirect to a different constructor. The list of
-   * [initializers] can be `null` if the constructor does not have any
-   * initializers. The [redirectedConstructor] can be `null` if the constructor
-   * does not redirect to a different constructor. The [body] can be `null` if
-   * the constructor does not have a body.
-   */
-  factory ConstructorDeclaration(
-          Comment comment,
-          List<Annotation> metadata,
-          Token externalKeyword,
-          Token constKeyword,
-          Token factoryKeyword,
-          Identifier returnType,
-          Token period,
-          SimpleIdentifier name,
-          FormalParameterList parameters,
-          Token separator,
-          List<ConstructorInitializer> initializers,
-          ConstructorName redirectedConstructor,
-          FunctionBody body) =>
-      new ConstructorDeclarationImpl(
-          comment,
-          metadata,
-          externalKeyword,
-          constKeyword,
-          factoryKeyword,
-          returnType,
-          period,
-          name,
-          parameters,
-          separator,
-          initializers,
-          redirectedConstructor,
-          body);
-
-  /**
    * Return the body of the constructor, or `null` if the constructor does not
    * have a body.
    */
@@ -2271,16 +1933,6 @@
  */
 abstract class ConstructorFieldInitializer extends ConstructorInitializer {
   /**
-   * Initialize a newly created field initializer to initialize the field with
-   * the given name to the value of the given expression. The [thisKeyword] and
-   * [period] can be `null` if the 'this' keyword was not specified.
-   */
-  factory ConstructorFieldInitializer(Token thisKeyword, Token period,
-          SimpleIdentifier fieldName, Token equals, Expression expression) =>
-      new ConstructorFieldInitializerImpl(
-          thisKeyword, period, fieldName, equals, expression);
-
-  /**
    * Return the token for the equal sign between the field name and the
    * expression.
    */
@@ -2360,13 +2012,6 @@
 abstract class ConstructorName extends AstNode
     implements ConstructorReferenceNode {
   /**
-   * Initialize a newly created constructor name. The [period] and [name] can be
-   * `null` if the constructor being named is the unnamed constructor.
-   */
-  factory ConstructorName(TypeName type, Token period, SimpleIdentifier name) =>
-      new ConstructorNameImpl(type, period, name);
-
-  /**
    * Return the name of the constructor, or `null` if the specified constructor
    * is the unnamed constructor.
    */
@@ -2430,14 +2075,6 @@
  */
 abstract class ContinueStatement extends Statement {
   /**
-   * Initialize a newly created continue statement. The [label] can be `null` if
-   * there is no label associated with the statement.
-   */
-  factory ContinueStatement(
-          Token continueKeyword, SimpleIdentifier label, Token semicolon) =>
-      new ContinueStatementImpl(continueKeyword, label, semicolon);
-
-  /**
    * Return the token representing the 'continue' keyword.
    */
   Token get continueKeyword;
@@ -2509,16 +2146,6 @@
  * Clients may not extend, implement or mix-in this class.
  */
 abstract class DeclaredIdentifier extends Declaration {
-  /**
-   * Initialize a newly created formal parameter. Either or both of the
-   * [comment] and [metadata] can be `null` if the declaration does not have the
-   * corresponding attribute. The [keyword] can be `null` if a type name is
-   * given. The [type] must be `null` if the keyword is 'var'.
-   */
-  factory DeclaredIdentifier(Comment comment, List<Annotation> metadata,
-          Token keyword, TypeName type, SimpleIdentifier identifier) =>
-      new DeclaredIdentifierImpl(comment, metadata, keyword, type, identifier);
-
   @override
   LocalVariableElement get element;
 
@@ -2583,14 +2210,6 @@
  */
 abstract class DefaultFormalParameter extends FormalParameter {
   /**
-   * Initialize a newly created default formal parameter. The [separator] and
-   * [defaultValue] can be `null` if there is no default value.
-   */
-  factory DefaultFormalParameter(NormalFormalParameter parameter,
-          ParameterKind kind, Token separator, Expression defaultValue) =>
-      new DefaultFormalParameterImpl(parameter, kind, separator, defaultValue);
-
-  /**
    * Return the expression computing the default value for the parameter, or
    * `null` if there is no default value.
    */
@@ -2672,20 +2291,6 @@
  */
 abstract class DoStatement extends Statement {
   /**
-   * Initialize a newly created do loop.
-   */
-  factory DoStatement(
-          Token doKeyword,
-          Statement body,
-          Token whileKeyword,
-          Token leftParenthesis,
-          Expression condition,
-          Token rightParenthesis,
-          Token semicolon) =>
-      new DoStatementImpl(doKeyword, body, whileKeyword, leftParenthesis,
-          condition, rightParenthesis, semicolon);
-
-  /**
    * Return the body of the loop.
    */
   Statement get body;
@@ -2767,11 +2372,6 @@
  */
 abstract class DottedName extends AstNode {
   /**
-   * Initialize a newly created dotted name.
-   */
-  factory DottedName(List<SimpleIdentifier> components) = DottedNameImpl;
-
-  /**
    * Return the components of the identifier.
    */
   NodeList<SimpleIdentifier> get components;
@@ -2791,11 +2391,6 @@
  */
 abstract class DoubleLiteral extends Literal {
   /**
-   * Initialize a newly created floating point literal.
-   */
-  factory DoubleLiteral(Token literal, double value) = DoubleLiteralImpl;
-
-  /**
    * Return the token representing the literal.
    */
   Token get literal;
@@ -2827,11 +2422,6 @@
  */
 abstract class EmptyFunctionBody extends FunctionBody {
   /**
-   * Initialize a newly created function body.
-   */
-  factory EmptyFunctionBody(Token semicolon) = EmptyFunctionBodyImpl;
-
-  /**
    * Return the token representing the semicolon that marks the end of the
    * function body.
    */
@@ -2854,11 +2444,6 @@
  */
 abstract class EmptyStatement extends Statement {
   /**
-   * Initialize a newly created empty statement.
-   */
-  factory EmptyStatement(Token semicolon) = EmptyStatementImpl;
-
-  /**
    * Return the semicolon terminating the statement.
    */
   Token get semicolon;
@@ -2876,16 +2461,6 @@
  */
 abstract class EnumConstantDeclaration extends Declaration {
   /**
-   * Initialize a newly created enum constant declaration. Either or both of the
-   * [comment] and [metadata] can be `null` if the constant does not have the
-   * corresponding attribute. (Technically, enum constants cannot have metadata,
-   * but we allow it for consistency.)
-   */
-  factory EnumConstantDeclaration(
-          Comment comment, List<Annotation> metadata, SimpleIdentifier name) =>
-      new EnumConstantDeclarationImpl(comment, metadata, name);
-
-  /**
    * Return the name of the constant.
    */
   SimpleIdentifier get name;
@@ -2906,23 +2481,6 @@
  */
 abstract class EnumDeclaration extends NamedCompilationUnitMember {
   /**
-   * Initialize a newly created enumeration declaration. Either or both of the
-   * [comment] and [metadata] can be `null` if the declaration does not have the
-   * corresponding attribute. The list of [constants] must contain at least one
-   * value.
-   */
-  factory EnumDeclaration(
-          Comment comment,
-          List<Annotation> metadata,
-          Token enumKeyword,
-          SimpleIdentifier name,
-          Token leftBracket,
-          List<EnumConstantDeclaration> constants,
-          Token rightBracket) =>
-      new EnumDeclarationImpl(comment, metadata, enumKeyword, name, leftBracket,
-          constants, rightBracket);
-
-  /**
    * Return the enumeration constants being declared.
    */
   NodeList<EnumConstantDeclaration> get constants;
@@ -2969,24 +2527,7 @@
  *
  * Clients may not extend, implement or mix-in this class.
  */
-abstract class ExportDirective extends NamespaceDirective {
-  /**
-   * Initialize a newly created export directive. Either or both of the
-   * [comment] and [metadata] can be `null` if the directive does not have the
-   * corresponding attribute. The list of [combinators] can be `null` if there
-   * are no combinators.
-   */
-  factory ExportDirective(
-          Comment comment,
-          List<Annotation> metadata,
-          Token keyword,
-          StringLiteral libraryUri,
-          List<Configuration> configurations,
-          List<Combinator> combinators,
-          Token semicolon) =>
-      new ExportDirectiveImpl(comment, metadata, keyword, libraryUri,
-          configurations, combinators, semicolon);
-}
+abstract class ExportDirective extends NamespaceDirective {}
 
 /**
  * A node that represents an expression.
@@ -3099,16 +2640,6 @@
  */
 abstract class ExpressionFunctionBody extends FunctionBody {
   /**
-   * Initialize a newly created function body consisting of a block of
-   * statements. The [keyword] can be `null` if the function body is not an
-   * async function body.
-   */
-  factory ExpressionFunctionBody(Token keyword, Token functionDefinition,
-          Expression expression, Token semicolon) =>
-      new ExpressionFunctionBodyImpl(
-          keyword, functionDefinition, expression, semicolon);
-
-  /**
    * Return the expression representing the body of the function.
    */
   Expression get expression;
@@ -3157,12 +2688,6 @@
  */
 abstract class ExpressionStatement extends Statement {
   /**
-   * Initialize a newly created expression statement.
-   */
-  factory ExpressionStatement(Expression expression, Token semicolon) =>
-      new ExpressionStatementImpl(expression, semicolon);
-
-  /**
    * Return the expression that comprises the statement.
    */
   Expression get expression;
@@ -3194,12 +2719,6 @@
  */
 abstract class ExtendsClause extends AstNode {
   /**
-   * Initialize a newly created extends clause.
-   */
-  factory ExtendsClause(Token extendsKeyword, TypeName superclass) =>
-      new ExtendsClauseImpl(extendsKeyword, superclass);
-
-  /**
    * Return the token representing the 'extends' keyword.
    */
   Token get extendsKeyword;
@@ -3230,21 +2749,6 @@
  */
 abstract class FieldDeclaration extends ClassMember {
   /**
-   * Initialize a newly created field declaration. Either or both of the
-   * [comment] and [metadata] can be `null` if the declaration does not have the
-   * corresponding attribute. The [staticKeyword] can be `null` if the field is
-   * not a static field.
-   */
-  factory FieldDeclaration(
-          Comment comment,
-          List<Annotation> metadata,
-          Token staticKeyword,
-          VariableDeclarationList fieldList,
-          Token semicolon) =>
-      new FieldDeclarationImpl(
-          comment, metadata, staticKeyword, fieldList, semicolon);
-
-  /**
    * Return the fields being declared.
    */
   VariableDeclarationList get fields;
@@ -3292,28 +2796,6 @@
  */
 abstract class FieldFormalParameter extends NormalFormalParameter {
   /**
-   * Initialize a newly created formal parameter. Either or both of the
-   * [comment] and [metadata] can be `null` if the parameter does not have the
-   * corresponding attribute. The [keyword] can be `null` if there is a type.
-   * The [type] must be `null` if the keyword is 'var'. The [thisKeyword] and
-   * [period] can be `null` if the keyword 'this' was not provided.  The
-   * [parameters] can be `null` if this is not a function-typed field formal
-   * parameter.
-   */
-  factory FieldFormalParameter(
-          Comment comment,
-          List<Annotation> metadata,
-          Token keyword,
-          TypeName type,
-          Token thisKeyword,
-          Token period,
-          SimpleIdentifier identifier,
-          TypeParameterList typeParameters,
-          FormalParameterList parameters) =>
-      new FieldFormalParameterImpl(comment, metadata, keyword, type,
-          thisKeyword, period, identifier, typeParameters, parameters);
-
-  /**
    * Return the token representing either the 'final', 'const' or 'var' keyword,
    * or `null` if no keyword was used.
    */
@@ -3394,54 +2876,6 @@
  */
 abstract class ForEachStatement extends Statement {
   /**
-   * Initialize a newly created for-each statement whose loop control variable
-   * is declared internally (in the for-loop part). The [awaitKeyword] can be
-   * `null` if this is not an asynchronous for loop.
-   */
-  factory ForEachStatement.withDeclaration(
-          Token awaitKeyword,
-          Token forKeyword,
-          Token leftParenthesis,
-          DeclaredIdentifier loopVariable,
-          Token inKeyword,
-          Expression iterator,
-          Token rightParenthesis,
-          Statement body) =>
-      new ForEachStatementImpl.withDeclaration(
-          awaitKeyword,
-          forKeyword,
-          leftParenthesis,
-          loopVariable,
-          inKeyword,
-          iterator,
-          rightParenthesis,
-          body);
-
-  /**
-   * Initialize a newly created for-each statement whose loop control variable
-   * is declared outside the for loop. The [awaitKeyword] can be `null` if this
-   * is not an asynchronous for loop.
-   */
-  factory ForEachStatement.withReference(
-          Token awaitKeyword,
-          Token forKeyword,
-          Token leftParenthesis,
-          SimpleIdentifier identifier,
-          Token inKeyword,
-          Expression iterator,
-          Token rightParenthesis,
-          Statement body) =>
-      new ForEachStatementImpl.withReference(
-          awaitKeyword,
-          forKeyword,
-          leftParenthesis,
-          identifier,
-          inKeyword,
-          iterator,
-          rightParenthesis,
-          body);
-
-  /**
    * Return the token representing the 'await' keyword, or `null` if there is no
    * 'await' keyword.
    */
@@ -3612,18 +3046,6 @@
  */
 abstract class FormalParameterList extends AstNode {
   /**
-   * Initialize a newly created parameter list. The list of [parameters] can be
-   * `null` if there are no parameters. The [leftDelimiter] and [rightDelimiter]
-   * can be `null` if there are no optional parameters.
-   */
-  factory FormalParameterList(
-      Token leftParenthesis,
-      List<FormalParameter> parameters,
-      Token leftDelimiter,
-      Token rightDelimiter,
-      Token rightParenthesis) = FormalParameterListImpl;
-
-  /**
    * Return the left square bracket ('[') or left curly brace ('{') introducing
    * the optional parameters, or `null` if there are no optional parameters.
    */
@@ -3697,35 +3119,6 @@
  */
 abstract class ForStatement extends Statement {
   /**
-   * Initialize a newly created for statement. Either the [variableList] or the
-   * [initialization] must be `null`. Either the [condition] and the list of
-   * [updaters] can be `null` if the loop does not have the corresponding
-   * attribute.
-   */
-  factory ForStatement(
-          Token forKeyword,
-          Token leftParenthesis,
-          VariableDeclarationList variableList,
-          Expression initialization,
-          Token leftSeparator,
-          Expression condition,
-          Token rightSeparator,
-          List<Expression> updaters,
-          Token rightParenthesis,
-          Statement body) =>
-      new ForStatementImpl(
-          forKeyword,
-          leftParenthesis,
-          variableList,
-          initialization,
-          leftSeparator,
-          condition,
-          rightSeparator,
-          updaters,
-          rightParenthesis,
-          body);
-
-  /**
    * Return the body of the loop.
    */
   Statement get body;
@@ -3905,25 +3298,6 @@
  * Clients may not extend, implement or mix-in this class.
  */
 abstract class FunctionDeclaration extends NamedCompilationUnitMember {
-  /**
-   * Initialize a newly created function declaration. Either or both of the
-   * [comment] and [metadata] can be `null` if the function does not have the
-   * corresponding attribute. The [externalKeyword] can be `null` if the
-   * function is not an external function. The [returnType] can be `null` if no
-   * return type was specified. The [propertyKeyword] can be `null` if the
-   * function is neither a getter or a setter.
-   */
-  factory FunctionDeclaration(
-          Comment comment,
-          List<Annotation> metadata,
-          Token externalKeyword,
-          TypeName returnType,
-          Token propertyKeyword,
-          SimpleIdentifier name,
-          FunctionExpression functionExpression) =>
-      new FunctionDeclarationImpl(comment, metadata, externalKeyword,
-          returnType, propertyKeyword, name, functionExpression);
-
   @override
   ExecutableElement get element;
 
@@ -3989,13 +3363,6 @@
  */
 abstract class FunctionDeclarationStatement extends Statement {
   /**
-   * Initialize a newly created function declaration statement.
-   */
-  factory FunctionDeclarationStatement(
-          FunctionDeclaration functionDeclaration) =
-      FunctionDeclarationStatementImpl;
-
-  /**
    * Return the function declaration being wrapped.
    */
   FunctionDeclaration get functionDeclaration;
@@ -4017,13 +3384,6 @@
  */
 abstract class FunctionExpression extends Expression {
   /**
-   * Initialize a newly created function declaration.
-   */
-  factory FunctionExpression(TypeParameterList typeParameters,
-          FormalParameterList parameters, FunctionBody body) =>
-      new FunctionExpressionImpl(typeParameters, parameters, body);
-
-  /**
    * Return the body of the function, or `null` if this is an external function.
    */
   FunctionBody get body;
@@ -4081,14 +3441,6 @@
  */
 abstract class FunctionExpressionInvocation extends InvocationExpression {
   /**
-   * Initialize a newly created function expression invocation.
-   */
-  factory FunctionExpressionInvocation(Expression function,
-          TypeArgumentList typeArguments, ArgumentList argumentList) =>
-      new FunctionExpressionInvocationImpl(
-          function, typeArguments, argumentList);
-
-  /**
    * Set the list of arguments to the method to the given [argumentList].
    */
   void set argumentList(ArgumentList argumentList);
@@ -4160,25 +3512,6 @@
  */
 abstract class FunctionTypeAlias extends TypeAlias {
   /**
-   * Initialize a newly created function type alias. Either or both of the
-   * [comment] and [metadata] can be `null` if the function does not have the
-   * corresponding attribute. The [returnType] can be `null` if no return type
-   * was specified. The [typeParameters] can be `null` if the function has no
-   * type parameters.
-   */
-  factory FunctionTypeAlias(
-          Comment comment,
-          List<Annotation> metadata,
-          Token keyword,
-          TypeName returnType,
-          SimpleIdentifier name,
-          TypeParameterList typeParameters,
-          FormalParameterList parameters,
-          Token semicolon) =>
-      new FunctionTypeAliasImpl(comment, metadata, keyword, returnType, name,
-          typeParameters, parameters, semicolon);
-
-  /**
    * Return the parameters associated with the function type.
    */
   FormalParameterList get parameters;
@@ -4224,23 +3557,6 @@
  */
 abstract class FunctionTypedFormalParameter extends NormalFormalParameter {
   /**
-   * Initialize a newly created formal parameter. Either or both of the
-   * [comment] and [metadata] can be `null` if the parameter does not have the
-   * corresponding attribute. The [returnType] can be `null` if no return type
-   * was specified.
-   */
-  factory FunctionTypedFormalParameter(
-          Comment comment,
-          List<Annotation> metadata,
-          TypeName returnType,
-          SimpleIdentifier identifier,
-          TypeParameterList typeParameters,
-          FormalParameterList parameters,
-          {Token question: null}) =>
-      new FunctionTypedFormalParameterImpl(comment, metadata, returnType,
-          identifier, typeParameters, parameters, question);
-
-  /**
    * Return the parameters of the function-typed parameter.
    */
   FormalParameterList get parameters;
@@ -4298,12 +3614,6 @@
  */
 abstract class HideCombinator extends Combinator {
   /**
-   * Initialize a newly created import show combinator.
-   */
-  factory HideCombinator(Token keyword, List<SimpleIdentifier> hiddenNames) =
-      HideCombinatorImpl;
-
-  /**
    * Return the list of names from the library that are hidden by this
    * combinator.
    */
@@ -4368,21 +3678,6 @@
  */
 abstract class IfStatement extends Statement {
   /**
-   * Initialize a newly created if statement. The [elseKeyword] and
-   * [elseStatement] can be `null` if there is no else clause.
-   */
-  factory IfStatement(
-          Token ifKeyword,
-          Token leftParenthesis,
-          Expression condition,
-          Token rightParenthesis,
-          Statement thenStatement,
-          Token elseKeyword,
-          Statement elseStatement) =>
-      new IfStatementImpl(ifKeyword, leftParenthesis, condition,
-          rightParenthesis, thenStatement, elseKeyword, elseStatement);
-
-  /**
    * Return the condition used to determine which of the statements is executed
    * next.
    */
@@ -4469,12 +3764,6 @@
  */
 abstract class ImplementsClause extends AstNode {
   /**
-   * Initialize a newly created implements clause.
-   */
-  factory ImplementsClause(Token implementsKeyword, List<TypeName> interfaces) =
-      ImplementsClauseImpl;
-
-  /**
    * Return the token representing the 'implements' keyword.
    */
   Token get implementsKeyword;
@@ -4605,38 +3894,6 @@
     }
     return 0;
   };
-
-  /**
-   * Initialize a newly created import directive. Either or both of the
-   * [comment] and [metadata] can be `null` if the function does not have the
-   * corresponding attribute. The [deferredKeyword] can be `null` if the import
-   * is not deferred. The [asKeyword] and [prefix] can be `null` if the import
-   * does not specify a prefix. The list of [combinators] can be `null` if there
-   * are no combinators.
-   */
-  factory ImportDirective(
-          Comment comment,
-          List<Annotation> metadata,
-          Token keyword,
-          StringLiteral libraryUri,
-          List<Configuration> configurations,
-          Token deferredKeyword,
-          Token asKeyword,
-          SimpleIdentifier prefix,
-          List<Combinator> combinators,
-          Token semicolon) =>
-      new ImportDirectiveImpl(
-          comment,
-          metadata,
-          keyword,
-          libraryUri,
-          configurations,
-          deferredKeyword,
-          asKeyword,
-          prefix,
-          combinators,
-          semicolon);
-
   /**
    * Return the token representing the 'as' keyword, or `null` if the imported
    * names are not prefixed.
@@ -4682,22 +3939,6 @@
 abstract class IndexExpression extends Expression
     implements MethodReferenceExpression {
   /**
-   * Initialize a newly created index expression.
-   */
-  factory IndexExpression.forCascade(Token period, Token leftBracket,
-          Expression index, Token rightBracket) =>
-      new IndexExpressionImpl.forCascade(
-          period, leftBracket, index, rightBracket);
-
-  /**
-   * Initialize a newly created index expression.
-   */
-  factory IndexExpression.forTarget(Expression target, Token leftBracket,
-          Expression index, Token rightBracket) =>
-      new IndexExpressionImpl.forTarget(
-          target, leftBracket, index, rightBracket);
-
-  /**
    * Return the auxiliary elements associated with this identifier, or `null` if
    * this identifier is not in both a getter and setter context. The auxiliary
    * elements hold the static and propagated elements associated with the getter
@@ -4816,14 +4057,6 @@
 abstract class InstanceCreationExpression extends Expression
     implements ConstructorReferenceNode {
   /**
-   * Initialize a newly created instance creation expression.
-   */
-  factory InstanceCreationExpression(Token keyword,
-          ConstructorName constructorName, ArgumentList argumentList) =>
-      new InstanceCreationExpressionImpl(
-          keyword, constructorName, argumentList);
-
-  /**
    * Return the list of arguments to the constructor.
    */
   ArgumentList get argumentList;
@@ -4880,11 +4113,6 @@
  */
 abstract class IntegerLiteral extends Literal {
   /**
-   * Initialize a newly created integer literal.
-   */
-  factory IntegerLiteral(Token literal, int value) = IntegerLiteralImpl;
-
-  /**
    * Return the token representing the literal.
    */
   Token get literal;
@@ -4927,13 +4155,6 @@
  */
 abstract class InterpolationExpression extends InterpolationElement {
   /**
-   * Initialize a newly created interpolation expression.
-   */
-  factory InterpolationExpression(
-          Token leftBracket, Expression expression, Token rightBracket) =>
-      new InterpolationExpressionImpl(leftBracket, expression, rightBracket);
-
-  /**
    * Return the expression to be evaluated for the value to be converted into a
    * string.
    */
@@ -4981,13 +4202,6 @@
  */
 abstract class InterpolationString extends InterpolationElement {
   /**
-   * Initialize a newly created string of characters that are part of a string
-   * interpolation.
-   */
-  factory InterpolationString(Token contents, String value) =
-      InterpolationStringImpl;
-
-  /**
    * Return the characters that will be added to the string.
    */
   Token get contents;
@@ -5095,14 +4309,6 @@
  */
 abstract class IsExpression extends Expression {
   /**
-   * Initialize a newly created is expression. The [notOperator] can be `null`
-   * if the sense of the test is not negated.
-   */
-  factory IsExpression(Expression expression, Token isOperator,
-          Token notOperator, TypeName type) =>
-      new IsExpressionImpl(expression, isOperator, notOperator, type);
-
-  /**
    * Return the expression used to compute the value whose type is being tested.
    */
   Expression get expression;
@@ -5154,12 +4360,6 @@
  */
 abstract class Label extends AstNode {
   /**
-   * Initialize a newly created label.
-   */
-  factory Label(SimpleIdentifier label, Token colon) =>
-      new LabelImpl(label, colon);
-
-  /**
    * Return the colon that separates the label from the statement.
    */
   Token get colon;
@@ -5191,12 +4391,6 @@
  */
 abstract class LabeledStatement extends Statement {
   /**
-   * Initialize a newly created labeled statement.
-   */
-  factory LabeledStatement(List<Label> labels, Statement statement) =>
-      new LabeledStatementImpl(labels, statement);
-
-  /**
    * Return the labels being associated with the statement.
    */
   NodeList<Label> get labels;
@@ -5223,16 +4417,6 @@
  */
 abstract class LibraryDirective extends Directive {
   /**
-   * Initialize a newly created library directive. Either or both of the
-   * [comment] and [metadata] can be `null` if the directive does not have the
-   * corresponding attribute.
-   */
-  factory LibraryDirective(Comment comment, List<Annotation> metadata,
-          Token libraryKeyword, LibraryIdentifier name, Token semicolon) =>
-      new LibraryDirectiveImpl(
-          comment, metadata, libraryKeyword, name, semicolon);
-
-  /**
    * Return the token representing the 'library' keyword.
    */
   Token get libraryKeyword;
@@ -5273,12 +4457,6 @@
  */
 abstract class LibraryIdentifier extends Identifier {
   /**
-   * Initialize a newly created prefixed identifier.
-   */
-  factory LibraryIdentifier(List<SimpleIdentifier> components) =
-      LibraryIdentifierImpl;
-
-  /**
    * Return the components of the identifier.
    */
   NodeList<SimpleIdentifier> get components;
@@ -5294,19 +4472,6 @@
  */
 abstract class ListLiteral extends TypedLiteral {
   /**
-   * Initialize a newly created list literal. The [constKeyword] can be `null`
-   * if the literal is not a constant. The [typeArguments] can be `null` if no
-   * type arguments were declared. The list of [elements] can be `null` if the
-   * list is empty.
-   */
-  factory ListLiteral(
-      Token constKeyword,
-      TypeArgumentList typeArguments,
-      Token leftBracket,
-      List<Expression> elements,
-      Token rightBracket) = ListLiteralImpl;
-
-  /**
    * Return the expressions used to compute the elements of the list.
    */
   NodeList<Expression> get elements;
@@ -5359,18 +4524,6 @@
  */
 abstract class MapLiteral extends TypedLiteral {
   /**
-   * Initialize a newly created map literal. The [constKeyword] can be `null` if
-   * the literal is not a constant. The [typeArguments] can be `null` if no type
-   * arguments were declared. The [entries] can be `null` if the map is empty.
-   */
-  factory MapLiteral(
-      Token constKeyword,
-      TypeArgumentList typeArguments,
-      Token leftBracket,
-      List<MapLiteralEntry> entries,
-      Token rightBracket) = MapLiteralImpl;
-
-  /**
    * Return the entries in the map.
    */
   NodeList<MapLiteralEntry> get entries;
@@ -5406,12 +4559,6 @@
  */
 abstract class MapLiteralEntry extends AstNode {
   /**
-   * Initialize a newly created map literal entry.
-   */
-  factory MapLiteralEntry(Expression key, Token separator, Expression value) =>
-      new MapLiteralEntryImpl(key, separator, value);
-
-  /**
    * Return the expression computing the key with which the value will be
    * associated.
    */
@@ -5464,42 +4611,6 @@
  */
 abstract class MethodDeclaration extends ClassMember {
   /**
-   * Initialize a newly created method declaration. Either or both of the
-   * [comment] and [metadata] can be `null` if the declaration does not have the
-   * corresponding attribute. The [externalKeyword] can be `null` if the method
-   * is not external. The [modifierKeyword] can be `null` if the method is
-   * neither abstract nor static. The [returnType] can be `null` if no return
-   * type was specified. The [propertyKeyword] can be `null` if the method is
-   * neither a getter or a setter. The [operatorKeyword] can be `null` if the
-   * method does not implement an operator. The [parameters] must be `null` if
-   * this method declares a getter.
-   */
-  factory MethodDeclaration(
-          Comment comment,
-          List<Annotation> metadata,
-          Token externalKeyword,
-          Token modifierKeyword,
-          TypeName returnType,
-          Token propertyKeyword,
-          Token operatorKeyword,
-          SimpleIdentifier name,
-          TypeParameterList typeParameters,
-          FormalParameterList parameters,
-          FunctionBody body) =>
-      new MethodDeclarationImpl(
-          comment,
-          metadata,
-          externalKeyword,
-          modifierKeyword,
-          returnType,
-          propertyKeyword,
-          operatorKeyword,
-          name,
-          typeParameters,
-          parameters,
-          body);
-
-  /**
    * Return the body of the method.
    */
   FunctionBody get body;
@@ -5641,19 +4752,6 @@
  */
 abstract class MethodInvocation extends InvocationExpression {
   /**
-   * Initialize a newly created method invocation. The [target] and [operator]
-   * can be `null` if there is no target.
-   */
-  factory MethodInvocation(
-          Expression target,
-          Token operator,
-          SimpleIdentifier methodName,
-          TypeArgumentList typeArguments,
-          ArgumentList argumentList) =>
-      new MethodInvocationImpl(
-          target, operator, methodName, typeArguments, argumentList);
-
-  /**
    * Set the list of arguments to the method to the given [argumentList].
    */
   void set argumentList(ArgumentList argumentList);
@@ -5794,12 +4892,6 @@
  */
 abstract class NamedExpression extends Expression {
   /**
-   * Initialize a newly created named expression..
-   */
-  factory NamedExpression(Label name, Expression expression) =>
-      new NamedExpressionImpl(name, expression);
-
-  /**
    * Return the element representing the parameter being named by this
    * expression, or `null` if the AST structure has not been resolved or if
    * there is no parameter with the same name as this expression.
@@ -5892,12 +4984,6 @@
  */
 abstract class NativeClause extends AstNode {
   /**
-   * Initialize a newly created native clause.
-   */
-  factory NativeClause(Token nativeKeyword, StringLiteral name) =>
-      new NativeClauseImpl(nativeKeyword, name);
-
-  /**
    * Return the name of the native object that implements the class.
    */
   StringLiteral get name;
@@ -5930,14 +5016,6 @@
  */
 abstract class NativeFunctionBody extends FunctionBody {
   /**
-   * Initialize a newly created function body consisting of the 'native' token,
-   * a string literal, and a semicolon.
-   */
-  factory NativeFunctionBody(
-          Token nativeKeyword, StringLiteral stringLiteral, Token semicolon) =>
-      new NativeFunctionBodyImpl(nativeKeyword, stringLiteral, semicolon);
-
-  /**
    * Return the token representing 'native' that marks the start of the function
    * body.
    */
@@ -5980,14 +5058,6 @@
  */
 abstract class NodeList<E extends AstNode> implements List<E> {
   /**
-   * Initialize a newly created list of nodes such that all of the nodes that
-   * are added to the list will have their parent set to the given [owner]. The
-   * list will initially be populated with the given [elements].
-   */
-  factory NodeList(AstNode owner, [List<E> elements]) =>
-      new NodeListImpl<E>(owner as AstNodeImpl, elements);
-
-  /**
    * Return the first token included in this node list's source range, or `null`
    * if the list is empty.
    */
@@ -6081,11 +5151,6 @@
  */
 abstract class NullLiteral extends Literal {
   /**
-   * Initialize a newly created null literal.
-   */
-  factory NullLiteral(Token literal) = NullLiteralImpl;
-
-  /**
    * Return the token representing the literal.
    */
   Token get literal;
@@ -6106,14 +5171,6 @@
  */
 abstract class ParenthesizedExpression extends Expression {
   /**
-   * Initialize a newly created parenthesized expression.
-   */
-  factory ParenthesizedExpression(Token leftParenthesis, Expression expression,
-          Token rightParenthesis) =>
-      new ParenthesizedExpressionImpl(
-          leftParenthesis, expression, rightParenthesis);
-
-  /**
    * Return the expression within the parentheses.
    */
   Expression get expression;
@@ -6154,18 +5211,6 @@
  */
 abstract class PartDirective extends UriBasedDirective {
   /**
-   * Initialize a newly created part directive. Either or both of the [comment]
-   * and [metadata] can be `null` if the directive does not have the
-   * corresponding attribute.
-   */
-  factory PartDirective(
-      Comment comment,
-      List<Annotation> metadata,
-      Token partKeyword,
-      StringLiteral partUri,
-      Token semicolon) = PartDirectiveImpl;
-
-  /**
    * Return the token representing the 'part' keyword.
    */
   Token get partKeyword;
@@ -6196,23 +5241,6 @@
  */
 abstract class PartOfDirective extends Directive {
   /**
-   * Initialize a newly created part-of directive. Either or both of the
-   * [comment] and [metadata] can be `null` if the directive does not have the
-   * corresponding attribute. Only one of the [uri] and [libraryName] should be
-   * provided.
-   */
-  factory PartOfDirective(
-          Comment comment,
-          List<Annotation> metadata,
-          Token partKeyword,
-          Token ofKeyword,
-          StringLiteral uri,
-          LibraryIdentifier libraryName,
-          Token semicolon) =>
-      new PartOfDirectiveImpl(comment, metadata, partKeyword, ofKeyword, uri,
-          libraryName, semicolon);
-
-  /**
    * Return the name of the library that the containing compilation unit is part
    * of.
    */
@@ -6280,12 +5308,6 @@
 abstract class PostfixExpression extends Expression
     implements MethodReferenceExpression {
   /**
-   * Initialize a newly created postfix expression.
-   */
-  factory PostfixExpression(Expression operand, Token operator) =>
-      new PostfixExpressionImpl(operand, operator);
-
-  /**
    * Return the expression computing the operand for the operator.
    */
   Expression get operand;
@@ -6318,13 +5340,6 @@
  */
 abstract class PrefixedIdentifier extends Identifier {
   /**
-   * Initialize a newly created prefixed identifier.
-   */
-  factory PrefixedIdentifier(
-          SimpleIdentifier prefix, Token period, SimpleIdentifier identifier) =>
-      new PrefixedIdentifierImpl(prefix, period, identifier);
-
-  /**
    * Return the identifier being prefixed.
    */
   SimpleIdentifier get identifier;
@@ -6378,12 +5393,6 @@
 abstract class PrefixExpression extends Expression
     implements MethodReferenceExpression {
   /**
-   * Initialize a newly created prefix expression.
-   */
-  factory PrefixExpression(Token operator, Expression operand) =>
-      new PrefixExpressionImpl(operator, operand);
-
-  /**
    * Return the expression computing the operand for the operator.
    */
   Expression get operand;
@@ -6419,13 +5428,6 @@
  */
 abstract class PropertyAccess extends Expression {
   /**
-   * Initialize a newly created property access expression.
-   */
-  factory PropertyAccess(
-          Expression target, Token operator, SimpleIdentifier propertyName) =>
-      new PropertyAccessImpl(target, operator, propertyName);
-
-  /**
    * Return `true` if this expression is cascaded. If it is, then the target of
    * this expression is not stored locally but is stored in the nearest ancestor
    * that is a [CascadeExpression].
@@ -6488,16 +5490,6 @@
 abstract class RedirectingConstructorInvocation extends ConstructorInitializer
     implements ConstructorReferenceNode {
   /**
-   * Initialize a newly created redirecting invocation to invoke the constructor
-   * with the given name with the given arguments. The [constructorName] can be
-   * `null` if the constructor being invoked is the unnamed constructor.
-   */
-  factory RedirectingConstructorInvocation(Token thisKeyword, Token period,
-          SimpleIdentifier constructorName, ArgumentList argumentList) =>
-      new RedirectingConstructorInvocationImpl(
-          thisKeyword, period, constructorName, argumentList);
-
-  /**
    * Return the list of arguments to the constructor.
    */
   ArgumentList get argumentList;
@@ -6552,11 +5544,6 @@
  */
 abstract class RethrowExpression extends Expression {
   /**
-   * Initialize a newly created rethrow expression.
-   */
-  factory RethrowExpression(Token rethrowKeyword) = RethrowExpressionImpl;
-
-  /**
    * Return the token representing the 'rethrow' keyword.
    */
   Token get rethrowKeyword;
@@ -6577,14 +5564,6 @@
  */
 abstract class ReturnStatement extends Statement {
   /**
-   * Initialize a newly created return statement. The [expression] can be `null`
-   * if no explicit value was provided.
-   */
-  factory ReturnStatement(
-          Token returnKeyword, Expression expression, Token semicolon) =>
-      new ReturnStatementImpl(returnKeyword, expression, semicolon);
-
-  /**
    * Return the expression computing the value to be returned, or `null` if no
    * explicit value was provided.
    */
@@ -6627,11 +5606,6 @@
  */
 abstract class ScriptTag extends AstNode {
   /**
-   * Initialize a newly created script tag.
-   */
-  factory ScriptTag(Token scriptTag) = ScriptTagImpl;
-
-  /**
    * Return the token representing this script tag.
    */
   Token get scriptTag;
@@ -6652,12 +5626,6 @@
  */
 abstract class ShowCombinator extends Combinator {
   /**
-   * Initialize a newly created import show combinator.
-   */
-  factory ShowCombinator(Token keyword, List<SimpleIdentifier> shownNames) =
-      ShowCombinatorImpl;
-
-  /**
    * Return the list of names from the library that are made visible by this
    * combinator.
    */
@@ -6674,17 +5642,6 @@
  */
 abstract class SimpleFormalParameter extends NormalFormalParameter {
   /**
-   * Initialize a newly created formal parameter. Either or both of the
-   * [comment] and [metadata] can be `null` if the parameter does not have the
-   * corresponding attribute. The [keyword] can be `null` if a type was
-   * specified. The [type] must be `null` if the keyword is 'var'.
-   */
-  factory SimpleFormalParameter(Comment comment, List<Annotation> metadata,
-          Token keyword, TypeName type, SimpleIdentifier identifier) =>
-      new SimpleFormalParameterImpl(
-          comment, metadata, keyword, type, identifier);
-
-  /**
    * Return the token representing either the 'final', 'const' or 'var' keyword,
    * or `null` if no keyword was used.
    */
@@ -6722,16 +5679,6 @@
  */
 abstract class SimpleIdentifier extends Identifier {
   /**
-   * Initialize a newly created identifier.
-   */
-  factory SimpleIdentifier(Token token, {bool isDeclaration: false}) {
-    if (isDeclaration) {
-      return new DeclaredSimpleIdentifier(token);
-    }
-    return new SimpleIdentifierImpl(token);
-  }
-
-  /**
    * Return the auxiliary elements associated with this identifier, or `null` if
    * this identifier is not in both a getter and setter context. The auxiliary
    * elements hold the static and propagated elements associated with the getter
@@ -6829,12 +5776,6 @@
  */
 abstract class SimpleStringLiteral extends SingleStringLiteral {
   /**
-   * Initialize a newly created simple string literal.
-   */
-  factory SimpleStringLiteral(Token literal, String value) =
-      SimpleStringLiteralImpl;
-
-  /**
    * Return the token representing the literal.
    */
   Token get literal;
@@ -6933,12 +5874,6 @@
  */
 abstract class StringInterpolation extends SingleStringLiteral {
   /**
-   * Initialize a newly created string interpolation expression.
-   */
-  factory StringInterpolation(List<InterpolationElement> elements) =
-      StringInterpolationImpl;
-
-  /**
    * Return the elements that will be composed to produce the resulting string.
    */
   NodeList<InterpolationElement> get elements;
@@ -6974,17 +5909,6 @@
 abstract class SuperConstructorInvocation extends ConstructorInitializer
     implements ConstructorReferenceNode {
   /**
-   * Initialize a newly created super invocation to invoke the inherited
-   * constructor with the given name with the given arguments. The [period] and
-   * [constructorName] can be `null` if the constructor being invoked is the
-   * unnamed constructor.
-   */
-  factory SuperConstructorInvocation(Token superKeyword, Token period,
-          SimpleIdentifier constructorName, ArgumentList argumentList) =>
-      new SuperConstructorInvocationImpl(
-          superKeyword, period, constructorName, argumentList);
-
-  /**
    * Return the list of arguments to the constructor.
    */
   ArgumentList get argumentList;
@@ -7039,11 +5963,6 @@
  */
 abstract class SuperExpression extends Expression {
   /**
-   * Initialize a newly created super expression.
-   */
-  factory SuperExpression(Token superKeyword) = SuperExpressionImpl;
-
-  /**
    * Return the token representing the 'super' keyword.
    */
   Token get superKeyword;
@@ -7064,14 +5983,6 @@
  */
 abstract class SwitchCase extends SwitchMember {
   /**
-   * Initialize a newly created switch case. The list of [labels] can be `null`
-   * if there are no labels.
-   */
-  factory SwitchCase(List<Label> labels, Token keyword, Expression expression,
-          Token colon, List<Statement> statements) =>
-      new SwitchCaseImpl(labels, keyword, expression, colon, statements);
-
-  /**
    * Return the expression controlling whether the statements will be executed.
    */
   Expression get expression;
@@ -7091,14 +6002,7 @@
  *
  * Clients may not extend, implement or mix-in this class.
  */
-abstract class SwitchDefault extends SwitchMember {
-  /**
-   * Initialize a newly created switch default. The list of [labels] can be
-   * `null` if there are no labels.
-   */
-  factory SwitchDefault(List<Label> labels, Token keyword, Token colon,
-      List<Statement> statements) = SwitchDefaultImpl;
-}
+abstract class SwitchDefault extends SwitchMember {}
 
 /**
  * An element within a switch statement.
@@ -7155,21 +6059,6 @@
  */
 abstract class SwitchStatement extends Statement {
   /**
-   * Initialize a newly created switch statement. The list of [members] can be
-   * `null` if there are no switch members.
-   */
-  factory SwitchStatement(
-          Token switchKeyword,
-          Token leftParenthesis,
-          Expression expression,
-          Token rightParenthesis,
-          Token leftBracket,
-          List<SwitchMember> members,
-          Token rightBracket) =>
-      new SwitchStatementImpl(switchKeyword, leftParenthesis, expression,
-          rightParenthesis, leftBracket, members, rightBracket);
-
-  /**
    * Return the expression used to determine which of the switch members will be
    * selected.
    */
@@ -7247,12 +6136,6 @@
  */
 abstract class SymbolLiteral extends Literal {
   /**
-   * Initialize a newly created symbol literal.
-   */
-  factory SymbolLiteral(Token poundSign, List<Token> components) =
-      SymbolLiteralImpl;
-
-  /**
    * Return the components of the literal.
    */
   List<Token> get components;
@@ -7278,11 +6161,6 @@
  */
 abstract class ThisExpression extends Expression {
   /**
-   * Initialize a newly created this expression.
-   */
-  factory ThisExpression(Token thisKeyword) = ThisExpressionImpl;
-
-  /**
    * Return the token representing the 'this' keyword.
    */
   Token get thisKeyword;
@@ -7303,12 +6181,6 @@
  */
 abstract class ThrowExpression extends Expression {
   /**
-   * Initialize a newly created throw expression.
-   */
-  factory ThrowExpression(Token throwKeyword, Expression expression) =>
-      new ThrowExpressionImpl(throwKeyword, expression);
-
-  /**
    * Return the expression computing the exception to be thrown.
    */
   Expression get expression;
@@ -7341,19 +6213,6 @@
  */
 abstract class TopLevelVariableDeclaration extends CompilationUnitMember {
   /**
-   * Initialize a newly created top-level variable declaration. Either or both
-   * of the [comment] and [metadata] can be `null` if the variable does not have
-   * the corresponding attribute.
-   */
-  factory TopLevelVariableDeclaration(
-          Comment comment,
-          List<Annotation> metadata,
-          VariableDeclarationList variableList,
-          Token semicolon) =>
-      new TopLevelVariableDeclarationImpl(
-          comment, metadata, variableList, semicolon);
-
-  /**
    * Return the semicolon terminating the declaration.
    */
   Token get semicolon;
@@ -7388,20 +6247,6 @@
  */
 abstract class TryStatement extends Statement {
   /**
-   * Initialize a newly created try statement. The list of [catchClauses] can be
-   * `null` if there are no catch clauses. The [finallyKeyword] and
-   * [finallyBlock] can be `null` if there is no finally clause.
-   */
-  factory TryStatement(
-          Token tryKeyword,
-          Block body,
-          List<CatchClause> catchClauses,
-          Token finallyKeyword,
-          Block finallyBlock) =>
-      new TryStatementImpl(
-          tryKeyword, body, catchClauses, finallyKeyword, finallyBlock);
-
-  /**
    * Return the body of the statement.
    */
   Block get body;
@@ -7493,13 +6338,6 @@
  */
 abstract class TypeArgumentList extends AstNode {
   /**
-   * Initialize a newly created list of type arguments.
-   */
-  factory TypeArgumentList(
-          Token leftBracket, List<TypeName> arguments, Token rightBracket) =
-      TypeArgumentListImpl;
-
-  /**
    * Return the type arguments associated with the type.
    */
   NodeList<TypeName> get arguments;
@@ -7569,14 +6407,6 @@
  */
 abstract class TypeName extends AstNode {
   /**
-   * Initialize a newly created type name. The [typeArguments] can be `null` if
-   * there are no type arguments.
-   */
-  factory TypeName(Identifier name, TypeArgumentList typeArguments,
-          {Token question: null}) =>
-      new TypeNameImpl(name, typeArguments, question);
-
-  /**
    * Return `true` if this type is a deferred type.
    *
    * 15.1 Static Types: A type <i>T</i> is deferred iff it is of the form
@@ -7640,16 +6470,6 @@
  */
 abstract class TypeParameter extends Declaration {
   /**
-   * Initialize a newly created type parameter. Either or both of the [comment]
-   * and [metadata] can be `null` if the parameter does not have the
-   * corresponding attribute. The [extendsKeyword] and [bound] can be `null` if
-   * the parameter does not have an upper bound.
-   */
-  factory TypeParameter(Comment comment, List<Annotation> metadata,
-          SimpleIdentifier name, Token extendsKeyword, TypeName bound) =>
-      new TypeParameterImpl(comment, metadata, name, extendsKeyword, bound);
-
-  /**
    * Return the name of the upper bound for legal arguments, or `null` if there
    * is no explicit upper bound.
    */
@@ -7693,14 +6513,6 @@
  */
 abstract class TypeParameterList extends AstNode {
   /**
-   * Initialize a newly created list of type parameters.
-   */
-  factory TypeParameterList(
-      Token leftBracket,
-      List<TypeParameter> typeParameters,
-      Token rightBracket) = TypeParameterListImpl;
-
-  /**
    * Return the left angle bracket.
    */
   Token get leftBracket;
@@ -7793,14 +6605,6 @@
  * Clients may not extend, implement or mix-in this class.
  */
 abstract class VariableDeclaration extends Declaration {
-  /**
-   * Initialize a newly created variable declaration. The [equals] and
-   * [initializer] can be `null` if there is no initializer.
-   */
-  factory VariableDeclaration(
-          SimpleIdentifier name, Token equals, Expression initializer) =>
-      new VariableDeclarationImpl(name, equals, initializer);
-
   @override
   VariableElement get element;
 
@@ -7867,17 +6671,6 @@
  */
 abstract class VariableDeclarationList extends AnnotatedNode {
   /**
-   * Initialize a newly created variable declaration list. Either or both of the
-   * [comment] and [metadata] can be `null` if the variable list does not have
-   * the corresponding attribute. The [keyword] can be `null` if a type was
-   * specified. The [type] must be `null` if the keyword is 'var'.
-   */
-  factory VariableDeclarationList(Comment comment, List<Annotation> metadata,
-          Token keyword, TypeName type, List<VariableDeclaration> variables) =>
-      new VariableDeclarationListImpl(
-          comment, metadata, keyword, type, variables);
-
-  /**
    * Return `true` if the variables in this list were declared with the 'const'
    * modifier.
    */
@@ -7931,13 +6724,6 @@
  */
 abstract class VariableDeclarationStatement extends Statement {
   /**
-   * Initialize a newly created variable declaration statement.
-   */
-  factory VariableDeclarationStatement(
-          VariableDeclarationList variableList, Token semicolon) =>
-      new VariableDeclarationStatementImpl(variableList, semicolon);
-
-  /**
    * Return the semicolon terminating the statement.
    */
   Token get semicolon;
@@ -7968,14 +6754,6 @@
  */
 abstract class WhileStatement extends Statement {
   /**
-   * Initialize a newly created while statement.
-   */
-  factory WhileStatement(Token whileKeyword, Token leftParenthesis,
-          Expression condition, Token rightParenthesis, Statement body) =>
-      new WhileStatementImpl(
-          whileKeyword, leftParenthesis, condition, rightParenthesis, body);
-
-  /**
    * Return the body of the loop.
    */
   Statement get body;
@@ -8038,12 +6816,6 @@
  */
 abstract class WithClause extends AstNode {
   /**
-   * Initialize a newly created with clause.
-   */
-  factory WithClause(Token withKeyword, List<TypeName> mixinTypes) =
-      WithClauseImpl;
-
-  /**
    * Return the names of the mixins that were specified.
    */
   NodeList<TypeName> get mixinTypes;
@@ -8069,14 +6841,6 @@
  */
 abstract class YieldStatement extends Statement {
   /**
-   * Initialize a newly created yield expression. The [star] can be `null` if no
-   * star was provided.
-   */
-  factory YieldStatement(Token yieldKeyword, Token star, Expression expression,
-          Token semicolon) =>
-      new YieldStatementImpl(yieldKeyword, star, expression, semicolon);
-
-  /**
    * Return the expression whose value will be yielded.
    */
   Expression get expression;
diff --git a/pkg/analyzer/lib/dart/element/element.dart b/pkg/analyzer/lib/dart/element/element.dart
index cee76da..a31f506 100644
--- a/pkg/analyzer/lib/dart/element/element.dart
+++ b/pkg/analyzer/lib/dart/element/element.dart
@@ -718,7 +718,7 @@
    * Use the given [visitor] to visit this element. Return the value returned by
    * the visitor as a result of visiting this element.
    */
-  accept(ElementVisitor visitor);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/> visitor);
 
   /**
    * Return the documentation comment for this element as it appears in the
diff --git a/pkg/analyzer/lib/error/error.dart b/pkg/analyzer/lib/error/error.dart
index 8a4f9e8..31fa75b 100644
--- a/pkg/analyzer/lib/error/error.dart
+++ b/pkg/analyzer/lib/error/error.dart
@@ -10,6 +10,7 @@
 import 'package:analyzer/error/listener.dart';
 import 'package:analyzer/src/dart/scanner/scanner.dart' show ScannerErrorCode;
 import 'package:analyzer/src/error/codes.dart';
+import 'package:analyzer/src/generated/resolver.dart' show ResolverErrorCode;
 import 'package:analyzer/src/generated/java_core.dart';
 import 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
 import 'package:analyzer/src/generated/source.dart';
@@ -442,6 +443,9 @@
   ParserErrorCode.WITH_WITHOUT_EXTENDS,
   ParserErrorCode.WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER,
   ParserErrorCode.WRONG_TERMINATOR_FOR_PARAMETER_GROUP,
+  ResolverErrorCode.BREAK_LABEL_ON_SWITCH_MEMBER,
+  ResolverErrorCode.CONTINUE_LABEL_ON_SWITCH,
+  ResolverErrorCode.MISSING_LIBRARY_DIRECTIVE_WITH_PART,
   ScannerErrorCode.ILLEGAL_CHARACTER,
   ScannerErrorCode.MISSING_DIGIT,
   ScannerErrorCode.MISSING_HEX_DIGIT,
@@ -564,6 +568,7 @@
   StaticWarningCode.STATIC_ACCESS_TO_INSTANCE_MEMBER,
   StaticWarningCode.SWITCH_EXPRESSION_NOT_ASSIGNABLE,
   StaticWarningCode.TYPE_ANNOTATION_DEFERRED_CLASS,
+  StaticWarningCode.TYPE_ANNOTATION_GENERIC_FUNCTION_PARAMETER,
   StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC,
   StaticWarningCode.TYPE_TEST_WITH_NON_TYPE,
   StaticWarningCode.TYPE_TEST_WITH_UNDEFINED_NAME,
@@ -872,17 +877,9 @@
   static const ErrorProperty<String> PARTS_LIBRARY_NAME =
       const ErrorProperty<String>('PARTS_LIBRARY_NAME', 1);
 
-  /**
-   * A property whose value is a list of [ExecutableElement] that should
-   * be but are not implemented by a concrete class.
-   */
-  static const ErrorProperty<List<ExecutableElement>> UNIMPLEMENTED_METHODS =
-      const ErrorProperty<List<ExecutableElement>>('UNIMPLEMENTED_METHODS', 2);
-
   static const List<ErrorProperty> values = const [
     NOT_INITIALIZED_FIELDS,
     PARTS_LIBRARY_NAME,
-    UNIMPLEMENTED_METHODS
   ];
 
   /**
diff --git a/pkg/analyzer/lib/file_system/memory_file_system.dart b/pkg/analyzer/lib/file_system/memory_file_system.dart
index 42731be..20f69e7 100644
--- a/pkg/analyzer/lib/file_system/memory_file_system.dart
+++ b/pkg/analyzer/lib/file_system/memory_file_system.dart
@@ -50,10 +50,11 @@
    * this class are never converted automatically.
    */
   String convertPath(String path) {
-    if (pathContext.style == pathos.windows.style &&
-        path.startsWith(pathos.posix.separator)) {
-      path = r'C:' +
-          path.replaceAll(pathos.posix.separator, pathos.windows.separator);
+    if (pathContext.style == pathos.windows.style) {
+      if (path.startsWith(pathos.posix.separator)) {
+        path = r'C:' + path;
+      }
+      path = path.replaceAll(pathos.posix.separator, pathos.windows.separator);
     }
     return path;
   }
diff --git a/pkg/analyzer/lib/src/dart/analysis/driver.dart b/pkg/analyzer/lib/src/dart/analysis/driver.dart
index a903243..4534661 100644
--- a/pkg/analyzer/lib/src/dart/analysis/driver.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/driver.dart
@@ -10,6 +10,7 @@
 import 'package:analyzer/dart/element/element.dart' show CompilationUnitElement;
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/error/listener.dart';
+import 'package:analyzer/exception/exception.dart';
 import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/src/context/context.dart';
 import 'package:analyzer/src/dart/analysis/byte_store.dart';
@@ -17,9 +18,11 @@
 import 'package:analyzer/src/dart/analysis/index.dart';
 import 'package:analyzer/src/dart/analysis/search.dart';
 import 'package:analyzer/src/dart/analysis/status.dart';
+import 'package:analyzer/src/dart/analysis/top_level_declaration.dart';
 import 'package:analyzer/src/generated/engine.dart'
     show AnalysisContext, AnalysisEngine, AnalysisOptions, ChangeSet;
 import 'package:analyzer/src/generated/source.dart';
+import 'package:analyzer/src/services/lint.dart';
 import 'package:analyzer/src/summary/api_signature.dart';
 import 'package:analyzer/src/summary/format.dart';
 import 'package:analyzer/src/summary/idl.dart';
@@ -64,8 +67,6 @@
  *
  *
  * TODO(scheglov) Clean up the list of implicitly analyzed files.
- *
- * TODO(scheglov) Handle not existing 'dart:x' URIs (while user is typing).
  */
 class AnalysisDriver {
   /**
@@ -157,6 +158,11 @@
   final _referencingNameTasks = <_FilesReferencingNameTask>[];
 
   /**
+   * The list of tasks to compute top-level declarations of a name.
+   */
+  final _topLevelNameDeclarationsTasks = <_TopLevelNameDeclarationsTask>[];
+
+  /**
    * The mapping from the files for which the index was requested using
    * [getIndex] to the [Completer]s to report the result.
    */
@@ -196,6 +202,12 @@
   final StatusSupport _statusSupport = new StatusSupport();
 
   /**
+   * The controller for the [exceptions] stream.
+   */
+  final StreamController<ExceptionResult> _exceptionController =
+      new StreamController<ExceptionResult>();
+
+  /**
    * The instance of the [Search] helper.
    */
   Search _search;
@@ -236,9 +248,24 @@
   Set<String> get addedFiles => _explicitFiles;
 
   /**
+   * Return the stream that produces [ExceptionResult]s.
+   */
+  Stream<ExceptionResult> get exceptions => _exceptionController.stream;
+
+  /**
+   * The current file system state.
+   */
+  FileSystemState get fsState => _fsState;
+
+  /**
    * Return the set of files that are known, i.e. added or used implicitly.
    */
-  Set<String> get knownFiles => _fsState.knownFiles;
+  Set<String> get knownFiles => _fsState.knownFilePaths;
+
+  /**
+   * Return the list of files that the driver should try to analyze sooner.
+   */
+  List<String> get priorityFiles => _priorityFiles.toList(growable: false);
 
   /**
    * Set the list of files that the driver should try to analyze sooner.
@@ -298,10 +325,13 @@
       return AnalysisDriverPriority.interactive;
     }
     if (_referencingNameTasks.isNotEmpty) {
-      return AnalysisDriverPriority.referencingName;
+      return AnalysisDriverPriority.interactive;
     }
     if (_indexRequestedFiles.isNotEmpty) {
-      return AnalysisDriverPriority.getIndex;
+      return AnalysisDriverPriority.interactive;
+    }
+    if (_topLevelNameDeclarationsTasks.isNotEmpty) {
+      return AnalysisDriverPriority.interactive;
     }
     if (_priorityFiles.isNotEmpty) {
       for (String path in _priorityFiles) {
@@ -433,6 +463,19 @@
   }
 
   /**
+   * Return a [Future] that completes with top-level declarations with the
+   * given [name] in all known libraries.
+   */
+  Future<List<TopLevelDeclarationInSource>> getTopLevelNameDeclarations(
+      String name) {
+    var task = new _TopLevelNameDeclarationsTask(this, name);
+    _topLevelNameDeclarationsTasks.add(task);
+    _statusSupport.transitionToAnalyzing();
+    _scheduler._notify(this);
+    return task.completer.future;
+  }
+
+  /**
    * Return a [Future] that completes with a [ParseResult] for the file
    * with the given [path].
    *
@@ -445,7 +488,7 @@
    * resolved unit).
    */
   Future<ParseResult> parseFile(String path) async {
-    FileState file = _fsState.getFileForPath(path);
+    FileState file = _verifyApiSignature(path);
     RecordingErrorListener listener = new RecordingErrorListener();
     CompilationUnit unit = file.parse(listener);
     return new ParseResult(file.path, file.uri, file.content, file.contentHash,
@@ -467,29 +510,6 @@
   }
 
   /**
-   * TODO(scheglov) see [_addToStoreUnlinked]
-   */
-  void _addToStoreLinked(
-      SummaryDataStore store, String uri, LinkedLibrary linked) {
-    store.linkedMap[uri] = linked;
-  }
-
-  /**
-   * TODO(scheglov) The existing [SummaryDataStore.addBundle] uses
-   * [PackageBundle.unlinkedUnitUris] to add [PackageBundle.unlinkedUnits].
-   * But we store unlinked bundles with the hash of the file content. This
-   * means that when two files are the same, but have different URIs, we
-   * add [UnlinkedUnit] with wrong URI.
-   *
-   * We need to clean this up.
-   */
-  void _addToStoreUnlinked(
-      SummaryDataStore store, Uri uri, UnlinkedUnit unlinked) {
-    String uriStr = uri.toString();
-    store.unlinkedMap[uriStr] = unlinked;
-  }
-
-  /**
    * Return the cached or newly computed analysis result of the file with the
    * given [path].
    *
@@ -574,6 +594,7 @@
         _logger.writeln('Computed new analysis result.');
         return _getAnalysisResultFromBytes(libraryFile, file, bytes,
             content: withUnit ? file.content : null,
+            withErrors: _explicitFiles.contains(path),
             resolvedUnit: withUnit ? resolvedUnit : null);
       } finally {
         analysisContext.dispose();
@@ -637,15 +658,11 @@
           libraries[library.uriStr] = library;
 
           // Append the defining unit.
-          {
-            UnlinkedUnit unlinked = library.unlinked;
-            _addToStoreUnlinked(store, library.uri, unlinked);
-          }
+          store.addUnlinkedUnit(library.uriStr, library.unlinked);
 
           // Append parts.
           for (FileState part in library.partedFiles) {
-            UnlinkedUnit unlinked = part.unlinked;
-            _addToStoreUnlinked(store, part.uri, unlinked);
+            store.addUnlinkedUnit(part.uriStr, part.unlinked);
           }
 
           // Append referenced libraries.
@@ -661,13 +678,15 @@
       Set<String> libraryUrisToLink = new Set<String>();
       _logger.run('Load linked bundles', () {
         for (FileState library in libraries.values) {
-          String key = '${library.transitiveSignature}.linked';
-          List<int> bytes = _byteStore.get(key);
-          if (bytes != null) {
-            LinkedLibrary linked = new LinkedLibrary.fromBuffer(bytes);
-            _addToStoreLinked(store, library.uriStr, linked);
-          } else {
-            libraryUrisToLink.add(library.uriStr);
+          if (library.exists) {
+            String key = '${library.transitiveSignature}.linked';
+            List<int> bytes = _byteStore.get(key);
+            if (bytes != null) {
+              LinkedLibrary linked = new LinkedLibrary.fromBuffer(bytes);
+              store.addLinkedLibrary(library.uriStr, linked);
+            } else {
+              libraryUrisToLink.add(library.uriStr);
+            }
           }
         }
         int numOfLoaded = libraries.length - libraryUrisToLink.length;
@@ -691,7 +710,7 @@
         String key = '${library.transitiveSignature}.linked';
         List<int> bytes = linkedBuilder.toBuffer();
         LinkedLibrary linked = new LinkedLibrary.fromBuffer(bytes);
-        _addToStoreLinked(store, uri, linked);
+        store.addLinkedLibrary(uri, linked);
         _byteStore.put(key, bytes);
       });
 
@@ -718,20 +737,15 @@
    */
   AnalysisResult _getAnalysisResultFromBytes(
       FileState libraryFile, FileState file, List<int> bytes,
-      {String content, CompilationUnit resolvedUnit}) {
+      {String content, bool withErrors: true, CompilationUnit resolvedUnit}) {
     var unit = new AnalysisDriverResolvedUnit.fromBuffer(bytes);
-    List<AnalysisError> errors = unit.errors.map((error) {
-      String errorName = error.uniqueName;
-      ErrorCode errorCode = errorCodeByUniqueName(errorName);
-      if (errorCode == null) {
-        throw new StateError('No ErrorCode for $errorName in $file');
-      }
-      return new AnalysisError.forValues(file.source, error.offset,
-          error.length, errorCode, error.message, error.correction);
-    }).toList();
+    List<AnalysisError> errors = withErrors
+        ? _getErrorsFromSerialized(file, unit.errors)
+        : const <AnalysisError>[];
     return new AnalysisResult(
         libraryFile,
         file,
+        this,
         sourceFactory,
         file.path,
         file.uri,
@@ -744,6 +758,26 @@
   }
 
   /**
+   * Return [AnalysisError]s for the given [serialized] errors.
+   */
+  List<AnalysisError> _getErrorsFromSerialized(
+      FileState file, List<AnalysisDriverUnitError> serialized) {
+    return serialized.map((error) {
+      String errorName = error.uniqueName;
+      ErrorCode errorCode =
+          errorCodeByUniqueName(errorName) ?? _lintCodeByUniqueName(errorName);
+      if (errorCode == null) {
+        // This could fail because the error code is no longer defined, or, in
+        // the case of a lint rule, if the lint rule has been disabled since the
+        // errors were written.
+        throw new StateError('No ErrorCode for $errorName in $file');
+      }
+      return new AnalysisError.forValues(file.source, error.offset,
+          error.length, errorCode, error.message, error.correction);
+    }).toList();
+  }
+
+  /**
    * Return the key to store fully resolved results for the [file] in the
    * [library] into the cache. Return `null` if the dependency signature is
    * not known yet.
@@ -757,6 +791,24 @@
   }
 
   /**
+   * Return the lint code with the given [errorName], or `null` if there is no
+   * lint registered with that name or the lint is not enabled in the analysis
+   * options.
+   */
+  ErrorCode _lintCodeByUniqueName(String errorName) {
+    if (errorName.startsWith('_LintCode.')) {
+      String lintName = errorName.substring(10);
+      List<Linter> lintRules = analysisOptions.lintRules;
+      for (Linter linter in lintRules) {
+        if (linter.name == lintName) {
+          return linter.lintCode;
+        }
+      }
+    }
+    return null;
+  }
+
+  /**
    * Perform a single chunk of work and produce [results].
    */
   Future<Null> _performWork() async {
@@ -770,21 +822,28 @@
     // Analyze a requested file.
     if (_requestedFiles.isNotEmpty) {
       String path = _requestedFiles.keys.first;
-      AnalysisResult result = _computeAnalysisResult(path, withUnit: true);
-      // If a part without a library, delay its analysis.
-      if (result == null) {
-        _requestedParts
-            .putIfAbsent(path, () => [])
-            .addAll(_requestedFiles.remove(path));
-        return;
+      try {
+        AnalysisResult result = _computeAnalysisResult(path, withUnit: true);
+        // If a part without a library, delay its analysis.
+        if (result == null) {
+          _requestedParts
+              .putIfAbsent(path, () => [])
+              .addAll(_requestedFiles.remove(path));
+          return;
+        }
+        // Notify the completers.
+        _requestedFiles.remove(path).forEach((completer) {
+          completer.complete(result);
+        });
+        // Remove from to be analyzed and produce it now.
+        _filesToAnalyze.remove(path);
+        _resultController.add(result);
+      } catch (exception, stackTrace) {
+        _filesToAnalyze.remove(path);
+        _requestedFiles.remove(path).forEach((completer) {
+          completer.completeError(exception, stackTrace);
+        });
       }
-      // Notify the completers.
-      _requestedFiles.remove(path).forEach((completer) {
-        completer.complete(result);
-      });
-      // Remove from to be analyzed and produce it now.
-      _filesToAnalyze.remove(path);
-      _resultController.add(result);
       return;
     }
 
@@ -808,15 +867,30 @@
       return;
     }
 
+    // Compute top-level declarations.
+    if (_topLevelNameDeclarationsTasks.isNotEmpty) {
+      _TopLevelNameDeclarationsTask task = _topLevelNameDeclarationsTasks.first;
+      bool isDone = await task.perform();
+      if (isDone) {
+        _topLevelNameDeclarationsTasks.remove(task);
+      }
+      return;
+    }
+
     // Analyze a priority file.
     if (_priorityFiles.isNotEmpty) {
       for (String path in _priorityFiles) {
         if (_filesToAnalyze.remove(path)) {
-          AnalysisResult result = _computeAnalysisResult(path, withUnit: true);
-          if (result == null) {
-            _partsToAnalyze.add(path);
-          } else {
-            _resultController.add(result);
+          try {
+            AnalysisResult result =
+                _computeAnalysisResult(path, withUnit: true);
+            if (result == null) {
+              _partsToAnalyze.add(path);
+            } else {
+              _resultController.add(result);
+            }
+          } catch (exception, stackTrace) {
+            _reportError(path, exception, stackTrace);
           }
           return;
         }
@@ -826,11 +900,15 @@
     // Analyze a general file.
     if (_filesToAnalyze.isNotEmpty) {
       String path = _removeFirst(_filesToAnalyze);
-      AnalysisResult result = _computeAnalysisResult(path, withUnit: false);
-      if (result == null) {
-        _partsToAnalyze.add(path);
-      } else {
-        _resultController.add(result);
+      try {
+        AnalysisResult result = _computeAnalysisResult(path, withUnit: false);
+        if (result == null) {
+          _partsToAnalyze.add(path);
+        } else {
+          _resultController.add(result);
+        }
+      } catch (exception, stackTrace) {
+        _reportError(path, exception, stackTrace);
       }
       return;
     }
@@ -838,29 +916,45 @@
     // Analyze a requested part file.
     if (_requestedParts.isNotEmpty) {
       String path = _requestedParts.keys.first;
-      AnalysisResult result = _computeAnalysisResult(path,
-          withUnit: true, asIsIfPartWithoutLibrary: true);
-      // Notify the completers.
-      _requestedParts.remove(path).forEach((completer) {
-        completer.complete(result);
-      });
-      // Remove from to be analyzed and produce it now.
-      _filesToAnalyze.remove(path);
-      _resultController.add(result);
+      try {
+        AnalysisResult result = _computeAnalysisResult(path,
+            withUnit: true, asIsIfPartWithoutLibrary: true);
+        // Notify the completers.
+        _requestedParts.remove(path).forEach((completer) {
+          completer.complete(result);
+        });
+        // Remove from to be analyzed and produce it now.
+        _partsToAnalyze.remove(path);
+        _resultController.add(result);
+      } catch (exception, stackTrace) {
+        _partsToAnalyze.remove(path);
+        _requestedParts.remove(path).forEach((completer) {
+          completer.completeError(exception, stackTrace);
+        });
+      }
       return;
     }
 
     // Analyze a general part.
     if (_partsToAnalyze.isNotEmpty) {
       String path = _removeFirst(_partsToAnalyze);
-      AnalysisResult result = _computeAnalysisResult(path,
-          withUnit: _priorityFiles.contains(path),
-          asIsIfPartWithoutLibrary: true);
-      _resultController.add(result);
+      try {
+        AnalysisResult result = _computeAnalysisResult(path,
+            withUnit: _priorityFiles.contains(path),
+            asIsIfPartWithoutLibrary: true);
+        _resultController.add(result);
+      } catch (exception, stackTrace) {
+        _reportError(path, exception, stackTrace);
+      }
       return;
     }
   }
 
+  void _reportError(String path, exception, StackTrace stackTrace) {
+    CaughtException caught = new CaughtException(exception, stackTrace);
+    _exceptionController.add(new ExceptionResult(path, caught));
+  }
+
   /**
    * Verify the API signature for the file with the given [path], and decide
    * which linked libraries should be invalidated, and files reanalyzed.
@@ -899,20 +993,34 @@
  * of the list, the earlier the corresponding [AnalysisDriver] should be asked
  * to perform work.
  */
-enum AnalysisDriverPriority {
-  nothing,
-  general,
-  priority,
-  referencingName,
-  getIndex,
-  interactive
-}
+enum AnalysisDriverPriority { nothing, general, priority, interactive }
 
 /**
  * Instances of this class schedule work in multiple [AnalysisDriver]s so that
  * work with the highest priority is performed first.
  */
 class AnalysisDriverScheduler {
+  /**
+   * Time interval in milliseconds before pumping the event queue.
+   *
+   * Relinquishing execution flow and running the event loop after every task
+   * has too much overhead. Instead we use a fixed length of time, so we can
+   * spend less time overall and still respond quickly enough.
+   */
+  static const int _MS_BEFORE_PUMPING_EVENT_QUEUE = 2;
+
+  /**
+   * Event queue pumping is required to allow IO and other asynchronous data
+   * processing while analysis is active. For example Analysis Server needs to
+   * be able to process `updateContent` or `setPriorityFiles` requests while
+   * background analysis is in progress.
+   *
+   * The number of pumpings is arbitrary, might be changed if we see that
+   * analysis or other data processing tasks are starving. Ideally we would
+   * need to run all asynchronous operations using a single global scheduler.
+   */
+  static const int _NUMBER_OF_EVENT_QUEUE_PUMPINGS = 128;
+
   final PerformanceLog _logger;
   final List<AnalysisDriver> _drivers = [];
   final Monitor _hasWork = new Monitor();
@@ -923,6 +1031,12 @@
   AnalysisDriverScheduler(this._logger);
 
   /**
+   * Return `true` if we are currently analyzing code.
+   */
+  bool get isAnalyzing =>
+      _statusSupport.currentStatus == AnalysisStatus.ANALYZING;
+
+  /**
    * Return the stream that produces [AnalysisStatus] events.
    */
   Stream<AnalysisStatus> get status => _statusSupport.stream;
@@ -972,18 +1086,14 @@
    * priority first.
    */
   Future<Null> _run() async {
+    Stopwatch timer = new Stopwatch()..start();
     PerformanceLogSection analysisSection;
     while (true) {
-      // Pump the event queue to allow IO and other asynchronous data
-      // processing while analysis is active. For example Analysis Server
-      // needs to be able to process `updateContent` or `setPriorityFiles`
-      // requests while background analysis is in progress.
-      //
-      // The number of pumpings is arbitrary, might be changed if we see that
-      // analysis or other data processing tasks are starving. Ideally we
-      // would need to be able to set priority of (continuous) asynchronous
-      // tasks.
-      await _pumpEventQueue(128);
+      // Pump the event queue.
+      if (timer.elapsedMilliseconds > _MS_BEFORE_PUMPING_EVENT_QUEUE) {
+        await _pumpEventQueue(_NUMBER_OF_EVENT_QUEUE_PUMPINGS);
+        timer.reset();
+      }
 
       await _hasWork.signal;
 
@@ -1046,6 +1156,11 @@
   final FileState _file;
 
   /**
+   * The [AnalysisDriver] that produced this result.
+   */
+  final AnalysisDriver driver;
+
+  /**
    * The [SourceFactory] with which the file was analyzed.
    */
   final SourceFactory sourceFactory;
@@ -1095,6 +1210,7 @@
   AnalysisResult(
       this._libraryFile,
       this._file,
+      this.driver,
       this.sourceFactory,
       this.path,
       this.uri,
@@ -1107,6 +1223,25 @@
 }
 
 /**
+ * Exception that happened during analysis.
+ */
+class ExceptionResult {
+  /**
+   * The path of the file being analyzed when the [exception] happened.
+   *
+   * Absolute and normalized.
+   */
+  final String path;
+
+  /**
+   * The exception during analysis of the file with the [path].
+   */
+  final CaughtException exception;
+
+  ExceptionResult(this.path, this.exception);
+}
+
+/**
  * The result of indexing of a single file.
  */
 class IndexResult {
@@ -1261,38 +1396,31 @@
   _FilesReferencingNameTask(this.driver, this.name);
 
   /**
-   * Perform work for a fixed length of time, and either complete the
-   * [completer] and return `true` to indicate that the task is done, return
-   * `false` to indicate that the task should continue to be run.
-   *
-   * Relinquishing execution flow and running event loop after every file
-   * works, but has too much overhead. Instead we use a fixed length of time,
-   * so we can spend less time overall and keep quick enough response time.
+   * Perform a single piece of work, and either complete the [completer] and
+   * return `true` to indicate that the task is done, return `false` to indicate
+   * that the task should continue to be run.
    */
   Future<bool> perform() async {
-    Stopwatch timer = new Stopwatch()..start();
-    while (timer.elapsedMilliseconds < 5) {
-      // Prepare files to check.
-      if (filesToCheck.isEmpty) {
-        Set<String> newFiles = driver.addedFiles.difference(checkedFiles);
-        filesToCheck.addAll(newFiles);
-      }
-
-      // If no more files to check, complete and done.
-      if (filesToCheck.isEmpty) {
-        completer.complete(referencingFiles);
-        return true;
-      }
-
-      // Check the next file.
-      String path = filesToCheck.removeLast();
-      FileState file = driver._fsState.getFileForPath(path);
-      if (file.referencedNames.contains(name)) {
-        referencingFiles.add(path);
-      }
-      checkedFiles.add(path);
+    // Prepare files to check.
+    if (filesToCheck.isEmpty) {
+      Set<String> newFiles = driver.addedFiles.difference(checkedFiles);
+      filesToCheck.addAll(newFiles);
     }
 
+    // If no more files to check, complete and done.
+    if (filesToCheck.isEmpty) {
+      completer.complete(referencingFiles);
+      return true;
+    }
+
+    // Check the next file.
+    String path = filesToCheck.removeLast();
+    FileState file = driver._fsState.getFileForPath(path);
+    if (file.referencedNames.contains(name)) {
+      referencingFiles.add(path);
+    }
+    checkedFiles.add(path);
+
     // We're not done yet.
     return false;
   }
@@ -1306,3 +1434,61 @@
   final SummaryDataStore store;
   _LibraryContext(this.file, this.store);
 }
+
+/**
+ * Task that computes top-level declarations for a certain name in all
+ * known libraries.
+ */
+class _TopLevelNameDeclarationsTask {
+  final AnalysisDriver driver;
+  final String name;
+  final Completer<List<TopLevelDeclarationInSource>> completer =
+      new Completer<List<TopLevelDeclarationInSource>>();
+
+  final List<TopLevelDeclarationInSource> libraryDeclarations =
+      <TopLevelDeclarationInSource>[];
+  final Set<String> checkedFiles = new Set<String>();
+  final List<String> filesToCheck = <String>[];
+
+  _TopLevelNameDeclarationsTask(this.driver, this.name);
+
+  /**
+   * Perform a single piece of work, and either complete the [completer] and
+   * return `true` to indicate that the task is done, return `false` to indicate
+   * that the task should continue to be run.
+   */
+  Future<bool> perform() async {
+    // Prepare files to check.
+    if (filesToCheck.isEmpty) {
+      filesToCheck.addAll(driver.addedFiles.difference(checkedFiles));
+      filesToCheck.addAll(driver.knownFiles.difference(checkedFiles));
+    }
+
+    // If no more files to check, complete and done.
+    if (filesToCheck.isEmpty) {
+      completer.complete(libraryDeclarations);
+      return true;
+    }
+
+    // Check the next file.
+    String path = filesToCheck.removeLast();
+    if (checkedFiles.add(path)) {
+      FileState file = driver._fsState.getFileForPath(path);
+      if (!file.isPart) {
+        bool isExported = false;
+        TopLevelDeclaration declaration = file.topLevelDeclarations[name];
+        if (declaration == null) {
+          declaration = file.exportedTopLevelDeclarations[name];
+          isExported = true;
+        }
+        if (declaration != null) {
+          libraryDeclarations.add(new TopLevelDeclarationInSource(
+              file.source, declaration, isExported));
+        }
+      }
+    }
+
+    // We're not done yet.
+    return false;
+  }
+}
diff --git a/pkg/analyzer/lib/src/dart/analysis/file_state.dart b/pkg/analyzer/lib/src/dart/analysis/file_state.dart
index 3a88ed6..7ab09c1 100644
--- a/pkg/analyzer/lib/src/dart/analysis/file_state.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/file_state.dart
@@ -12,6 +12,7 @@
 import 'package:analyzer/src/dart/analysis/byte_store.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart';
 import 'package:analyzer/src/dart/analysis/referenced_names.dart';
+import 'package:analyzer/src/dart/analysis/top_level_declaration.dart';
 import 'package:analyzer/src/dart/scanner/reader.dart';
 import 'package:analyzer/src/dart/scanner/scanner.dart';
 import 'package:analyzer/src/generated/engine.dart';
@@ -22,6 +23,7 @@
 import 'package:analyzer/src/summary/api_signature.dart';
 import 'package:analyzer/src/summary/format.dart';
 import 'package:analyzer/src/summary/idl.dart';
+import 'package:analyzer/src/summary/name_filter.dart';
 import 'package:analyzer/src/summary/summarize_ast.dart';
 import 'package:analyzer/src/util/fast_uri.dart';
 import 'package:convert/convert.dart';
@@ -83,6 +85,7 @@
    */
   Source source;
 
+  bool _exists;
   String _content;
   String _contentHash;
   LineInfo _lineInfo;
@@ -93,10 +96,15 @@
   List<FileState> _importedFiles;
   List<FileState> _exportedFiles;
   List<FileState> _partedFiles;
+  List<NameFilter> _exportFilters;
+
   Set<FileState> _directReferencedFiles = new Set<FileState>();
   Set<FileState> _transitiveFiles;
   String _transitiveSignature;
 
+  Map<String, TopLevelDeclaration> _topLevelDeclarations;
+  Map<String, TopLevelDeclaration> _exportedTopLevelDeclarations;
+
   FileState._(this._fsState, this.path, this.uri, this.source);
 
   /**
@@ -121,10 +129,60 @@
   Set<FileState> get directReferencedFiles => _directReferencedFiles;
 
   /**
+   * Return `true` if the file exists.
+   */
+  bool get exists => _exists;
+
+  /**
    * The list of files this file exports.
    */
   List<FileState> get exportedFiles => _exportedFiles;
 
+  /**
+   * Return [TopLevelDeclaration]s exported from the this library file. The
+   * keys to the map are names of declarations.
+   */
+  Map<String, TopLevelDeclaration> get exportedTopLevelDeclarations {
+    if (_exportedTopLevelDeclarations == null) {
+      _exportedTopLevelDeclarations = <String, TopLevelDeclaration>{};
+
+      Set<FileState> seenLibraries = new Set<FileState>();
+
+      /**
+       * Compute [TopLevelDeclaration]s exported from the [library].
+       */
+      Map<String, TopLevelDeclaration> computeExported(FileState library) {
+        var declarations = <String, TopLevelDeclaration>{};
+        if (seenLibraries.add(library)) {
+          // Append the exported declarations.
+          for (int i = 0; i < library._exportedFiles.length; i++) {
+            Map<String, TopLevelDeclaration> exported =
+                computeExported(library._exportedFiles[i]);
+            for (TopLevelDeclaration t in exported.values) {
+              if (library._exportFilters[i].accepts(t.name)) {
+                declarations[t.name] = t;
+              }
+            }
+          }
+
+          // Append the library declarations.
+          declarations.addAll(library.topLevelDeclarations);
+          for (FileState part in library.partedFiles) {
+            declarations.addAll(part.topLevelDeclarations);
+          }
+
+          // We're done with this library.
+          seenLibraries.remove(library);
+        }
+
+        return declarations;
+      }
+
+      _exportedTopLevelDeclarations = computeExported(this);
+    }
+    return _exportedTopLevelDeclarations;
+  }
+
   @override
   int get hashCode => uri.hashCode;
 
@@ -168,6 +226,56 @@
   Set<String> get referencedNames => _referencedNames;
 
   /**
+   * Return public top-level declarations declared in the file. The keys to the
+   * map are names of declarations.
+   */
+  Map<String, TopLevelDeclaration> get topLevelDeclarations {
+    if (_topLevelDeclarations == null) {
+      _topLevelDeclarations = <String, TopLevelDeclaration>{};
+
+      void addDeclaration(TopLevelDeclarationKind kind, String name) {
+        if (!name.startsWith('_')) {
+          _topLevelDeclarations[name] = new TopLevelDeclaration(kind, name);
+        }
+      }
+
+      // Add types.
+      for (UnlinkedClass type in unlinked.classes) {
+        addDeclaration(TopLevelDeclarationKind.type, type.name);
+      }
+      for (UnlinkedEnum type in unlinked.enums) {
+        addDeclaration(TopLevelDeclarationKind.type, type.name);
+      }
+      for (UnlinkedTypedef type in unlinked.typedefs) {
+        addDeclaration(TopLevelDeclarationKind.type, type.name);
+      }
+      // Add functions and variables.
+      Set<String> addedVariableNames = new Set<String>();
+      for (UnlinkedExecutable executable in unlinked.executables) {
+        String name = executable.name;
+        if (executable.kind == UnlinkedExecutableKind.functionOrMethod) {
+          addDeclaration(TopLevelDeclarationKind.function, name);
+        } else if (executable.kind == UnlinkedExecutableKind.getter ||
+            executable.kind == UnlinkedExecutableKind.setter) {
+          if (executable.kind == UnlinkedExecutableKind.setter) {
+            name = name.substring(0, name.length - 1);
+          }
+          if (addedVariableNames.add(name)) {
+            addDeclaration(TopLevelDeclarationKind.variable, name);
+          }
+        }
+      }
+      for (UnlinkedVariable variable in unlinked.variables) {
+        String name = variable.name;
+        if (addedVariableNames.add(name)) {
+          addDeclaration(TopLevelDeclarationKind.variable, name);
+        }
+      }
+    }
+    return _topLevelDeclarations;
+  }
+
+  /**
    * Return the set of transitive files - the file itself and all of the
    * directly or indirectly referenced files.
    */
@@ -249,15 +357,10 @@
     try {
       _content = _fsState._contentOverlay[path];
       _content ??= _fsState._resourceProvider.getFile(path).readAsStringSync();
+      _exists = true;
     } catch (_) {
       _content = '';
-      // TODO(scheglov) We fail to report URI_DOES_NOT_EXIST.
-      // On one hand we need to provide an unlinked bundle to prevent
-      // analysis context from reading the file (we want it to work
-      // hermetically and handle one one file at a time). OTOH,
-      // ResynthesizerResultProvider happily reports that any source in the
-      // SummaryDataStore has MODIFICATION_TIME `0`. We need to return `-1`
-      // for missing files. Maybe add this feature to SummaryDataStore?
+      _exists = false;
     }
 
     // Compute the content hash.
@@ -298,18 +401,24 @@
     _referencedNames = new Set<String>.from(driverUnlinkedUnit.referencedNames);
     _unlinked = driverUnlinkedUnit.unit;
     _lineInfo = new LineInfo(_unlinked.lineStarts);
+    _topLevelDeclarations = null;
+
+    // Prepare API signature.
     List<int> newApiSignature = _unlinked.apiSignature;
     bool apiSignatureChanged = _apiSignature != null &&
         !_equalByteLists(_apiSignature, newApiSignature);
     _apiSignature = newApiSignature;
 
-    // If the API signature changed, flush transitive signatures.
+    // The API signature changed.
+    //   Flush transitive signatures of affected files.
+    //   Flush exported top-level declarations of all files.
     if (apiSignatureChanged) {
       for (FileState file in _fsState._uriToFile.values) {
         if (file._transitiveFiles != null &&
             file._transitiveFiles.contains(this)) {
           file._transitiveSignature = null;
         }
+        file._exportedTopLevelDeclarations = null;
       }
     }
 
@@ -324,6 +433,7 @@
     _importedFiles = <FileState>[];
     _exportedFiles = <FileState>[];
     _partedFiles = <FileState>[];
+    _exportFilters = <NameFilter>[];
     for (UnlinkedImport import in _unlinked.imports) {
       if (!import.isImplicit) {
         String uri = import.uri;
@@ -341,6 +451,8 @@
         FileState file = _fileForRelativeUri(uri);
         if (file != null) {
           _exportedFiles.add(file);
+          _exportFilters
+              .add(new NameFilter.forUnlinkedCombinators(export.combinators));
         }
       }
     }
@@ -465,9 +577,15 @@
   }
 
   /**
-   * Return the set of known files.
+   * Return the set of known file paths.
    */
-  Set<String> get knownFiles => _pathToFiles.keys.toSet();
+  Set<String> get knownFilePaths => _pathToFiles.keys.toSet();
+
+  /**
+   * Return the known files.
+   */
+  Iterable<FileState> get knownFiles =>
+      _pathToFiles.values.map((files) => files.first);
 
   @visibleForTesting
   FileSystemStateTestView get test => _testView;
diff --git a/pkg/analyzer/lib/src/dart/analysis/search.dart b/pkg/analyzer/lib/src/dart/analysis/search.dart
index 8ca2f31..907ad15 100644
--- a/pkg/analyzer/lib/src/dart/analysis/search.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/search.dart
@@ -9,10 +9,12 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/visitor.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart';
+import 'package:analyzer/src/dart/analysis/file_state.dart';
 import 'package:analyzer/src/dart/analysis/index.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/member.dart';
+import 'package:analyzer/src/dart/resolver/scope.dart' show NamespaceBuilder;
 import 'package:analyzer/src/summary/idl.dart';
 import 'package:collection/collection.dart';
 
@@ -40,11 +42,12 @@
 
     ElementKind kind = element.kind;
     if (kind == ElementKind.CLASS ||
-        kind == ElementKind.COMPILATION_UNIT ||
         kind == ElementKind.CONSTRUCTOR ||
         kind == ElementKind.FUNCTION_TYPE_ALIAS ||
         kind == ElementKind.SETTER) {
       return _searchReferences(element);
+    } else if (kind == ElementKind.COMPILATION_UNIT) {
+      return _searchReferences_CompilationUnit(element);
     } else if (kind == ElementKind.GETTER) {
       return _searchReferences_Getter(element);
     } else if (kind == ElementKind.FIELD ||
@@ -55,6 +58,8 @@
         return _searchReferences_Local(element, (n) => n is Block);
       }
       return _searchReferences_Function(element);
+    } else if (kind == ElementKind.IMPORT) {
+      return _searchReferences_Import(element);
     } else if (kind == ElementKind.LABEL ||
         kind == ElementKind.LOCAL_VARIABLE) {
       return _searchReferences_Local(element, (n) => n is Block);
@@ -66,10 +71,25 @@
       return _searchReferences_Local(
           element, (n) => n.parent is CompilationUnit);
     }
-    // TODO(scheglov) support other kinds
     return const <SearchResult>[];
   }
 
+  /**
+   * Returns subtypes of the given [type].
+   */
+  Future<List<SearchResult>> subTypes(ClassElement type) async {
+    if (type == null) {
+      return const <SearchResult>[];
+    }
+    List<SearchResult> results = <SearchResult>[];
+    await _addResults(results, type, {
+      IndexRelationKind.IS_EXTENDED_BY: SearchResultKind.REFERENCE,
+      IndexRelationKind.IS_MIXED_IN_BY: SearchResultKind.REFERENCE,
+      IndexRelationKind.IS_IMPLEMENTED_BY: SearchResultKind.REFERENCE
+    });
+    return results;
+  }
+
   Future<Null> _addResults(List<SearchResult> results, Element element,
       Map<IndexRelationKind, SearchResultKind> relationToResultKind) async {
     String path = element.source.fullName;
@@ -79,26 +99,54 @@
       return;
     }
 
-    // TODO(scheglov) optimize for private elements
+    // Prepare the element name.
     String name = element.displayName;
+    if (element is ConstructorElement) {
+      name = element.enclosingElement.displayName;
+    }
 
     // Prepare the list of files that reference the element name.
-    List<String> files = await _driver.getFilesReferencingName(name);
-    if (!files.contains(path) && _driver.addedFiles.contains(path)) {
-      files.add(path);
+    List<String> files = <String>[];
+    if (name.startsWith('_')) {
+      String libraryPath = element.library.source.fullName;
+      if (_driver.addedFiles.contains(libraryPath)) {
+        FileState library = _driver.fsState.getFileForPath(libraryPath);
+        List<FileState> candidates = [library]..addAll(library.partedFiles);
+        for (FileState file in candidates) {
+          if (file.path == path || file.referencedNames.contains(name)) {
+            files.add(file.path);
+          }
+        }
+      }
+    } else {
+      files = await _driver.getFilesReferencingName(name);
+      if (!files.contains(path) && _driver.addedFiles.contains(path)) {
+        files.add(path);
+      }
     }
 
     // Check the index of every file that references the element name.
     for (String file in files) {
-      IndexResult result = await _driver.getIndex(file);
-      _IndexRequest request = new _IndexRequest(result.index);
-      int elementId = request.findElementId(element);
-      if (elementId != -1) {
-        CompilationUnitElement unitElement = result.unitElement;
-        List<SearchResult> fileResults =
-            request.getRelations(elementId, relationToResultKind, unitElement);
-        results.addAll(fileResults);
-      }
+      await _addResultsInFile(results, element, relationToResultKind, file);
+    }
+  }
+
+  /**
+   * Add results for [element] usage in the given [file].
+   */
+  Future<Null> _addResultsInFile(
+      List<SearchResult> results,
+      Element element,
+      Map<IndexRelationKind, SearchResultKind> relationToResultKind,
+      String file) async {
+    IndexResult result = await _driver.getIndex(file);
+    _IndexRequest request = new _IndexRequest(result.index);
+    int elementId = request.findElementId(element);
+    if (elementId != -1) {
+      CompilationUnitElement unitElement = result.unitElement;
+      List<SearchResult> fileResults =
+          request.getRelations(elementId, relationToResultKind, unitElement);
+      results.addAll(fileResults);
     }
   }
 
@@ -109,6 +157,33 @@
     return results;
   }
 
+  Future<List<SearchResult>> _searchReferences_CompilationUnit(
+      CompilationUnitElement element) async {
+    String path = element.source.fullName;
+
+    // If the path is not known, then the file is not referenced.
+    if (!_driver.fsState.knownFilePaths.contains(path)) {
+      return const <SearchResult>[];
+    }
+
+    // Check every file that references the given path.
+    List<SearchResult> results = <SearchResult>[];
+    for (FileState file in _driver.fsState.knownFiles) {
+      for (FileState referencedFile in file.directReferencedFiles) {
+        if (referencedFile.path == path) {
+          await _addResultsInFile(
+              results,
+              element,
+              const {
+                IndexRelationKind.IS_REFERENCED_BY: SearchResultKind.REFERENCE
+              },
+              file.path);
+        }
+      }
+    }
+    return results;
+  }
+
   Future<List<SearchResult>> _searchReferences_Field(
       PropertyInducingElement field) async {
     List<SearchResult> results = <SearchResult>[];
@@ -155,6 +230,27 @@
     return results;
   }
 
+  Future<List<SearchResult>> _searchReferences_Import(
+      ImportElement element) async {
+    // Search only in drivers to which the library was added.
+    String path = element.source.fullName;
+    if (!_driver.addedFiles.contains(path)) {
+      return const <SearchResult>[];
+    }
+
+    List<SearchResult> results = <SearchResult>[];
+    LibraryElement libraryElement = element.library;
+    for (CompilationUnitElement unitElement in libraryElement.units) {
+      String unitPath = unitElement.source.fullName;
+      AnalysisResult unitAnalysisResult = await _driver.getResult(unitPath);
+      _ImportElementReferencesVisitor visitor =
+          new _ImportElementReferencesVisitor(element, unitElement);
+      unitAnalysisResult.unit.accept(visitor);
+      results.addAll(visitor.results);
+    }
+    return results;
+  }
+
   Future<List<SearchResult>> _searchReferences_Local(
       Element element, bool isRootNode(AstNode n)) async {
     String path = element.source.fullName;
@@ -309,6 +405,72 @@
   }
 }
 
+/**
+ * Visitor that adds [SearchResult]s for references to the [importElement].
+ */
+class _ImportElementReferencesVisitor extends RecursiveAstVisitor {
+  final List<SearchResult> results = <SearchResult>[];
+
+  final ImportElement importElement;
+  final CompilationUnitElement enclosingUnitElement;
+
+  Set<Element> importedElements;
+
+  _ImportElementReferencesVisitor(
+      ImportElement element, this.enclosingUnitElement)
+      : importElement = element {
+    importedElements = new NamespaceBuilder()
+        .createImportNamespaceForDirective(element)
+        .definedNames
+        .values
+        .toSet();
+  }
+
+  @override
+  visitExportDirective(ExportDirective node) {}
+
+  @override
+  visitImportDirective(ImportDirective node) {}
+
+  @override
+  visitSimpleIdentifier(SimpleIdentifier node) {
+    if (node.inDeclarationContext()) {
+      return;
+    }
+    if (importElement.prefix != null) {
+      if (node.staticElement == importElement.prefix) {
+        AstNode parent = node.parent;
+        if (parent is PrefixedIdentifier && parent.prefix == node) {
+          if (importedElements.contains(parent.staticElement)) {
+            _addResultForPrefix(node, parent.identifier);
+          }
+        }
+        if (parent is MethodInvocation && parent.target == node) {
+          if (importedElements.contains(parent.methodName.staticElement)) {
+            _addResultForPrefix(node, parent.methodName);
+          }
+        }
+      }
+    } else {
+      if (importedElements.contains(node.staticElement)) {
+        _addResult(node.offset, 0);
+      }
+    }
+  }
+
+  void _addResult(int offset, int length) {
+    Element enclosingElement =
+        _getEnclosingElement(enclosingUnitElement, offset);
+    results.add(new SearchResult._(importElement, enclosingElement,
+        SearchResultKind.REFERENCE, offset, length, true, false));
+  }
+
+  void _addResultForPrefix(SimpleIdentifier prefixNode, AstNode nextNode) {
+    int prefixOffset = prefixNode.offset;
+    _addResult(prefixOffset, nextNode.offset - prefixOffset);
+  }
+}
+
 class _IndexRequest {
   final AnalysisDriverUnitIndex index;
 
diff --git a/pkg/analyzer/lib/src/dart/analysis/status.dart b/pkg/analyzer/lib/src/dart/analysis/status.dart
index 3e2d79c..000c966 100644
--- a/pkg/analyzer/lib/src/dart/analysis/status.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/status.dart
@@ -70,6 +70,11 @@
   AnalysisStatus _currentStatus = AnalysisStatus.IDLE;
 
   /**
+   * Return the last status sent to the [stream].
+   */
+  AnalysisStatus get currentStatus => _currentStatus;
+
+  /**
    * Return the stream that produces [AnalysisStatus] events.
    */
   Stream<AnalysisStatus> get stream => _statusController.stream;
diff --git a/pkg/analyzer/lib/src/dart/analysis/top_level_declaration.dart b/pkg/analyzer/lib/src/dart/analysis/top_level_declaration.dart
new file mode 100644
index 0000000..8f1d640
--- /dev/null
+++ b/pkg/analyzer/lib/src/dart/analysis/top_level_declaration.dart
@@ -0,0 +1,50 @@
+// 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.
+
+import 'package:front_end/src/base/source.dart';
+
+/**
+ * Information about a single top-level declaration.
+ */
+class TopLevelDeclaration {
+  final TopLevelDeclarationKind kind;
+  final String name;
+
+  TopLevelDeclaration(this.kind, this.name);
+
+  @override
+  String toString() => '($kind, $name)';
+}
+
+/**
+ * A declaration in a source.
+ */
+class TopLevelDeclarationInSource {
+  /**
+   * The declaring source.
+   */
+  final Source source;
+
+  /**
+   * The declaration.
+   */
+  final TopLevelDeclaration declaration;
+
+  /**
+   * Is `true` if the [declaration] is exported, not declared in the [source].
+   */
+  final bool isExported;
+
+  TopLevelDeclarationInSource(this.source, this.declaration, this.isExported);
+
+  @override
+  String toString() => '($source, $declaration, $isExported)';
+}
+
+/**
+ * Kind of a top-level declaration.
+ *
+ * We don't need it to be precise, just enough to support quick fixes.
+ */
+enum TopLevelDeclarationKind { type, function, variable }
diff --git a/pkg/analyzer/lib/src/dart/ast/utilities.dart b/pkg/analyzer/lib/src/dart/ast/utilities.dart
index 7dd0e48..3efd68b 100644
--- a/pkg/analyzer/lib/src/dart/ast/utilities.dart
+++ b/pkg/analyzer/lib/src/dart/ast/utilities.dart
@@ -7,6 +7,7 @@
 import 'dart:collection';
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
@@ -120,10 +121,10 @@
 
   @override
   AdjacentStrings visitAdjacentStrings(AdjacentStrings node) =>
-      new AdjacentStrings(cloneNodeList(node.strings));
+      astFactory.adjacentStrings(cloneNodeList(node.strings));
 
   @override
-  Annotation visitAnnotation(Annotation node) => new Annotation(
+  Annotation visitAnnotation(Annotation node) => astFactory.annotation(
       cloneToken(node.atSign),
       cloneNode(node.name),
       cloneToken(node.period),
@@ -131,20 +132,20 @@
       cloneNode(node.arguments));
 
   @override
-  ArgumentList visitArgumentList(ArgumentList node) => new ArgumentList(
+  ArgumentList visitArgumentList(ArgumentList node) => astFactory.argumentList(
       cloneToken(node.leftParenthesis),
       cloneNodeList(node.arguments),
       cloneToken(node.rightParenthesis));
 
   @override
-  AsExpression visitAsExpression(AsExpression node) => new AsExpression(
+  AsExpression visitAsExpression(AsExpression node) => astFactory.asExpression(
       cloneNode(node.expression),
       cloneToken(node.asOperator),
       cloneNode(node.type));
 
   @override
   AstNode visitAssertInitializer(AssertInitializer node) =>
-      new AssertInitializer(
+      astFactory.assertInitializer(
           cloneToken(node.assertKeyword),
           cloneToken(node.leftParenthesis),
           cloneNode(node.condition),
@@ -153,56 +154,56 @@
           cloneToken(node.rightParenthesis));
 
   @override
-  AstNode visitAssertStatement(AssertStatement node) => new AssertStatement(
-      cloneToken(node.assertKeyword),
-      cloneToken(node.leftParenthesis),
-      cloneNode(node.condition),
-      cloneToken(node.comma),
-      cloneNode(node.message),
-      cloneToken(node.rightParenthesis),
-      cloneToken(node.semicolon));
+  AstNode visitAssertStatement(AssertStatement node) =>
+      astFactory.assertStatement(
+          cloneToken(node.assertKeyword),
+          cloneToken(node.leftParenthesis),
+          cloneNode(node.condition),
+          cloneToken(node.comma),
+          cloneNode(node.message),
+          cloneToken(node.rightParenthesis),
+          cloneToken(node.semicolon));
 
   @override
   AssignmentExpression visitAssignmentExpression(AssignmentExpression node) =>
-      new AssignmentExpression(cloneNode(node.leftHandSide),
+      astFactory.assignmentExpression(cloneNode(node.leftHandSide),
           cloneToken(node.operator), cloneNode(node.rightHandSide));
 
   @override
   AwaitExpression visitAwaitExpression(AwaitExpression node) =>
-      new AwaitExpression(
+      astFactory.awaitExpression(
           cloneToken(node.awaitKeyword), cloneNode(node.expression));
 
   @override
   BinaryExpression visitBinaryExpression(BinaryExpression node) =>
-      new BinaryExpression(cloneNode(node.leftOperand),
+      astFactory.binaryExpression(cloneNode(node.leftOperand),
           cloneToken(node.operator), cloneNode(node.rightOperand));
 
   @override
-  Block visitBlock(Block node) => new Block(cloneToken(node.leftBracket),
+  Block visitBlock(Block node) => astFactory.block(cloneToken(node.leftBracket),
       cloneNodeList(node.statements), cloneToken(node.rightBracket));
 
   @override
   BlockFunctionBody visitBlockFunctionBody(BlockFunctionBody node) =>
-      new BlockFunctionBody(cloneToken(node.keyword), cloneToken(node.star),
-          cloneNode(node.block));
+      astFactory.blockFunctionBody(cloneToken(node.keyword),
+          cloneToken(node.star), cloneNode(node.block));
 
   @override
   BooleanLiteral visitBooleanLiteral(BooleanLiteral node) =>
-      new BooleanLiteral(cloneToken(node.literal), node.value);
+      astFactory.booleanLiteral(cloneToken(node.literal), node.value);
 
   @override
-  BreakStatement visitBreakStatement(BreakStatement node) => new BreakStatement(
-      cloneToken(node.breakKeyword),
-      cloneNode(node.label),
-      cloneToken(node.semicolon));
+  BreakStatement visitBreakStatement(BreakStatement node) =>
+      astFactory.breakStatement(cloneToken(node.breakKeyword),
+          cloneNode(node.label), cloneToken(node.semicolon));
 
   @override
   CascadeExpression visitCascadeExpression(CascadeExpression node) =>
-      new CascadeExpression(
+      astFactory.cascadeExpression(
           cloneNode(node.target), cloneNodeList(node.cascadeSections));
 
   @override
-  CatchClause visitCatchClause(CatchClause node) => new CatchClause(
+  CatchClause visitCatchClause(CatchClause node) => astFactory.catchClause(
       cloneToken(node.onKeyword),
       cloneNode(node.exceptionType),
       cloneToken(node.catchKeyword),
@@ -215,7 +216,7 @@
 
   @override
   ClassDeclaration visitClassDeclaration(ClassDeclaration node) {
-    ClassDeclaration copy = new ClassDeclaration(
+    ClassDeclaration copy = astFactory.classDeclaration(
         cloneNode(node.documentationComment),
         cloneNodeList(node.metadata),
         cloneToken(node.abstractKeyword),
@@ -235,7 +236,7 @@
   @override
   ClassTypeAlias visitClassTypeAlias(ClassTypeAlias node) {
     cloneToken(node.abstractKeyword);
-    return new ClassTypeAlias(
+    return astFactory.classTypeAlias(
         cloneNode(node.documentationComment),
         cloneNodeList(node.metadata),
         cloneToken(node.typedefKeyword),
@@ -252,22 +253,22 @@
   @override
   Comment visitComment(Comment node) {
     if (node.isDocumentation) {
-      return Comment.createDocumentationCommentWithReferences(
+      return astFactory.documentationComment(
           cloneTokenList(node.tokens), cloneNodeList(node.references));
     } else if (node.isBlock) {
-      return Comment.createBlockComment(cloneTokenList(node.tokens));
+      return astFactory.blockComment(cloneTokenList(node.tokens));
     }
-    return Comment.createEndOfLineComment(cloneTokenList(node.tokens));
+    return astFactory.endOfLineComment(cloneTokenList(node.tokens));
   }
 
   @override
   CommentReference visitCommentReference(CommentReference node) =>
-      new CommentReference(
+      astFactory.commentReference(
           cloneToken(node.newKeyword), cloneNode(node.identifier));
 
   @override
   CompilationUnit visitCompilationUnit(CompilationUnit node) {
-    CompilationUnit clone = new CompilationUnit(
+    CompilationUnit clone = astFactory.compilationUnit(
         cloneToken(node.beginToken),
         cloneNode(node.scriptTag),
         cloneNodeList(node.directives),
@@ -280,7 +281,7 @@
   @override
   ConditionalExpression visitConditionalExpression(
           ConditionalExpression node) =>
-      new ConditionalExpression(
+      astFactory.conditionalExpression(
           cloneNode(node.condition),
           cloneToken(node.question),
           cloneNode(node.thenExpression),
@@ -288,19 +289,20 @@
           cloneNode(node.elseExpression));
 
   @override
-  Configuration visitConfiguration(Configuration node) => new Configuration(
-      cloneToken(node.ifKeyword),
-      cloneToken(node.leftParenthesis),
-      cloneNode(node.name),
-      cloneToken(node.equalToken),
-      cloneNode(node.value),
-      cloneToken(node.rightParenthesis),
-      cloneNode(node.uri));
+  Configuration visitConfiguration(Configuration node) =>
+      astFactory.configuration(
+          cloneToken(node.ifKeyword),
+          cloneToken(node.leftParenthesis),
+          cloneNode(node.name),
+          cloneToken(node.equalToken),
+          cloneNode(node.value),
+          cloneToken(node.rightParenthesis),
+          cloneNode(node.uri));
 
   @override
   ConstructorDeclaration visitConstructorDeclaration(
           ConstructorDeclaration node) =>
-      new ConstructorDeclaration(
+      astFactory.constructorDeclaration(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.externalKeyword),
@@ -318,7 +320,7 @@
   @override
   ConstructorFieldInitializer visitConstructorFieldInitializer(
           ConstructorFieldInitializer node) =>
-      new ConstructorFieldInitializer(
+      astFactory.constructorFieldInitializer(
           cloneToken(node.thisKeyword),
           cloneToken(node.period),
           cloneNode(node.fieldName),
@@ -327,17 +329,17 @@
 
   @override
   ConstructorName visitConstructorName(ConstructorName node) =>
-      new ConstructorName(
+      astFactory.constructorName(
           cloneNode(node.type), cloneToken(node.period), cloneNode(node.name));
 
   @override
   ContinueStatement visitContinueStatement(ContinueStatement node) =>
-      new ContinueStatement(cloneToken(node.continueKeyword),
+      astFactory.continueStatement(cloneToken(node.continueKeyword),
           cloneNode(node.label), cloneToken(node.semicolon));
 
   @override
   DeclaredIdentifier visitDeclaredIdentifier(DeclaredIdentifier node) =>
-      new DeclaredIdentifier(
+      astFactory.declaredIdentifier(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.keyword),
@@ -347,11 +349,11 @@
   @override
   DefaultFormalParameter visitDefaultFormalParameter(
           DefaultFormalParameter node) =>
-      new DefaultFormalParameter(cloneNode(node.parameter), node.kind,
+      astFactory.defaultFormalParameter(cloneNode(node.parameter), node.kind,
           cloneToken(node.separator), cloneNode(node.defaultValue));
 
   @override
-  DoStatement visitDoStatement(DoStatement node) => new DoStatement(
+  DoStatement visitDoStatement(DoStatement node) => astFactory.doStatement(
       cloneToken(node.doKeyword),
       cloneNode(node.body),
       cloneToken(node.whileKeyword),
@@ -362,28 +364,28 @@
 
   @override
   DottedName visitDottedName(DottedName node) =>
-      new DottedName(cloneNodeList(node.components));
+      astFactory.dottedName(cloneNodeList(node.components));
 
   @override
   DoubleLiteral visitDoubleLiteral(DoubleLiteral node) =>
-      new DoubleLiteral(cloneToken(node.literal), node.value);
+      astFactory.doubleLiteral(cloneToken(node.literal), node.value);
 
   @override
   EmptyFunctionBody visitEmptyFunctionBody(EmptyFunctionBody node) =>
-      new EmptyFunctionBody(cloneToken(node.semicolon));
+      astFactory.emptyFunctionBody(cloneToken(node.semicolon));
 
   @override
   EmptyStatement visitEmptyStatement(EmptyStatement node) =>
-      new EmptyStatement(cloneToken(node.semicolon));
+      astFactory.emptyStatement(cloneToken(node.semicolon));
 
   @override
   AstNode visitEnumConstantDeclaration(EnumConstantDeclaration node) =>
-      new EnumConstantDeclaration(cloneNode(node.documentationComment),
+      astFactory.enumConstantDeclaration(cloneNode(node.documentationComment),
           cloneNodeList(node.metadata), cloneNode(node.name));
 
   @override
   EnumDeclaration visitEnumDeclaration(EnumDeclaration node) =>
-      new EnumDeclaration(
+      astFactory.enumDeclaration(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.enumKeyword),
@@ -394,7 +396,7 @@
 
   @override
   ExportDirective visitExportDirective(ExportDirective node) {
-    ExportDirectiveImpl directive = new ExportDirective(
+    ExportDirectiveImpl directive = astFactory.exportDirective(
         cloneNode(node.documentationComment),
         cloneNodeList(node.metadata),
         cloneToken(node.keyword),
@@ -412,7 +414,7 @@
   @override
   ExpressionFunctionBody visitExpressionFunctionBody(
           ExpressionFunctionBody node) =>
-      new ExpressionFunctionBody(
+      astFactory.expressionFunctionBody(
           cloneToken(node.keyword),
           cloneToken(node.functionDefinition),
           cloneNode(node.expression),
@@ -420,16 +422,17 @@
 
   @override
   ExpressionStatement visitExpressionStatement(ExpressionStatement node) =>
-      new ExpressionStatement(
+      astFactory.expressionStatement(
           cloneNode(node.expression), cloneToken(node.semicolon));
 
   @override
-  ExtendsClause visitExtendsClause(ExtendsClause node) => new ExtendsClause(
-      cloneToken(node.extendsKeyword), cloneNode(node.superclass));
+  ExtendsClause visitExtendsClause(ExtendsClause node) =>
+      astFactory.extendsClause(
+          cloneToken(node.extendsKeyword), cloneNode(node.superclass));
 
   @override
   FieldDeclaration visitFieldDeclaration(FieldDeclaration node) =>
-      new FieldDeclaration(
+      astFactory.fieldDeclaration(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.staticKeyword),
@@ -438,7 +441,7 @@
 
   @override
   FieldFormalParameter visitFieldFormalParameter(FieldFormalParameter node) =>
-      new FieldFormalParameter(
+      astFactory.fieldFormalParameter(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.keyword),
@@ -453,7 +456,7 @@
   ForEachStatement visitForEachStatement(ForEachStatement node) {
     DeclaredIdentifier loopVariable = node.loopVariable;
     if (loopVariable == null) {
-      return new ForEachStatement.withReference(
+      return astFactory.forEachStatementWithReference(
           cloneToken(node.awaitKeyword),
           cloneToken(node.forKeyword),
           cloneToken(node.leftParenthesis),
@@ -463,7 +466,7 @@
           cloneToken(node.rightParenthesis),
           cloneNode(node.body));
     }
-    return new ForEachStatement.withDeclaration(
+    return astFactory.forEachStatementWithDeclaration(
         cloneToken(node.awaitKeyword),
         cloneToken(node.forKeyword),
         cloneToken(node.leftParenthesis),
@@ -476,7 +479,7 @@
 
   @override
   FormalParameterList visitFormalParameterList(FormalParameterList node) =>
-      new FormalParameterList(
+      astFactory.formalParameterList(
           cloneToken(node.leftParenthesis),
           cloneNodeList(node.parameters),
           cloneToken(node.leftDelimiter),
@@ -484,7 +487,7 @@
           cloneToken(node.rightParenthesis));
 
   @override
-  ForStatement visitForStatement(ForStatement node) => new ForStatement(
+  ForStatement visitForStatement(ForStatement node) => astFactory.forStatement(
       cloneToken(node.forKeyword),
       cloneToken(node.leftParenthesis),
       cloneNode(node.variables),
@@ -498,7 +501,7 @@
 
   @override
   FunctionDeclaration visitFunctionDeclaration(FunctionDeclaration node) =>
-      new FunctionDeclaration(
+      astFactory.functionDeclaration(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.externalKeyword),
@@ -510,22 +513,23 @@
   @override
   FunctionDeclarationStatement visitFunctionDeclarationStatement(
           FunctionDeclarationStatement node) =>
-      new FunctionDeclarationStatement(cloneNode(node.functionDeclaration));
+      astFactory
+          .functionDeclarationStatement(cloneNode(node.functionDeclaration));
 
   @override
   FunctionExpression visitFunctionExpression(FunctionExpression node) =>
-      new FunctionExpression(cloneNode(node.typeParameters),
+      astFactory.functionExpression(cloneNode(node.typeParameters),
           cloneNode(node.parameters), cloneNode(node.body));
 
   @override
   FunctionExpressionInvocation visitFunctionExpressionInvocation(
           FunctionExpressionInvocation node) =>
-      new FunctionExpressionInvocation(cloneNode(node.function),
+      astFactory.functionExpressionInvocation(cloneNode(node.function),
           cloneNode(node.typeArguments), cloneNode(node.argumentList));
 
   @override
   FunctionTypeAlias visitFunctionTypeAlias(FunctionTypeAlias node) =>
-      new FunctionTypeAlias(
+      astFactory.functionTypeAlias(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.typedefKeyword),
@@ -538,7 +542,7 @@
   @override
   FunctionTypedFormalParameter visitFunctionTypedFormalParameter(
           FunctionTypedFormalParameter node) =>
-      new FunctionTypedFormalParameter(
+      astFactory.functionTypedFormalParameter(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneNode(node.returnType),
@@ -547,11 +551,12 @@
           cloneNode(node.parameters));
 
   @override
-  HideCombinator visitHideCombinator(HideCombinator node) => new HideCombinator(
-      cloneToken(node.keyword), cloneNodeList(node.hiddenNames));
+  HideCombinator visitHideCombinator(HideCombinator node) =>
+      astFactory.hideCombinator(
+          cloneToken(node.keyword), cloneNodeList(node.hiddenNames));
 
   @override
-  IfStatement visitIfStatement(IfStatement node) => new IfStatement(
+  IfStatement visitIfStatement(IfStatement node) => astFactory.ifStatement(
       cloneToken(node.ifKeyword),
       cloneToken(node.leftParenthesis),
       cloneNode(node.condition),
@@ -562,12 +567,12 @@
 
   @override
   ImplementsClause visitImplementsClause(ImplementsClause node) =>
-      new ImplementsClause(
+      astFactory.implementsClause(
           cloneToken(node.implementsKeyword), cloneNodeList(node.interfaces));
 
   @override
   ImportDirective visitImportDirective(ImportDirective node) {
-    ImportDirectiveImpl directive = new ImportDirective(
+    ImportDirectiveImpl directive = astFactory.importDirective(
         cloneNode(node.documentationComment),
         cloneNodeList(node.metadata),
         cloneToken(node.keyword),
@@ -589,13 +594,13 @@
   IndexExpression visitIndexExpression(IndexExpression node) {
     Token period = node.period;
     if (period == null) {
-      return new IndexExpression.forTarget(
+      return astFactory.indexExpressionForTarget(
           cloneNode(node.target),
           cloneToken(node.leftBracket),
           cloneNode(node.index),
           cloneToken(node.rightBracket));
     } else {
-      return new IndexExpression.forCascade(
+      return astFactory.indexExpressionForCascade(
           cloneToken(period),
           cloneToken(node.leftBracket),
           cloneNode(node.index),
@@ -606,25 +611,25 @@
   @override
   InstanceCreationExpression visitInstanceCreationExpression(
           InstanceCreationExpression node) =>
-      new InstanceCreationExpression(cloneToken(node.keyword),
+      astFactory.instanceCreationExpression(cloneToken(node.keyword),
           cloneNode(node.constructorName), cloneNode(node.argumentList));
 
   @override
   IntegerLiteral visitIntegerLiteral(IntegerLiteral node) =>
-      new IntegerLiteral(cloneToken(node.literal), node.value);
+      astFactory.integerLiteral(cloneToken(node.literal), node.value);
 
   @override
   InterpolationExpression visitInterpolationExpression(
           InterpolationExpression node) =>
-      new InterpolationExpression(cloneToken(node.leftBracket),
+      astFactory.interpolationExpression(cloneToken(node.leftBracket),
           cloneNode(node.expression), cloneToken(node.rightBracket));
 
   @override
   InterpolationString visitInterpolationString(InterpolationString node) =>
-      new InterpolationString(cloneToken(node.contents), node.value);
+      astFactory.interpolationString(cloneToken(node.contents), node.value);
 
   @override
-  IsExpression visitIsExpression(IsExpression node) => new IsExpression(
+  IsExpression visitIsExpression(IsExpression node) => astFactory.isExpression(
       cloneNode(node.expression),
       cloneToken(node.isOperator),
       cloneToken(node.notOperator),
@@ -632,16 +637,15 @@
 
   @override
   Label visitLabel(Label node) =>
-      new Label(cloneNode(node.label), cloneToken(node.colon));
+      astFactory.label(cloneNode(node.label), cloneToken(node.colon));
 
   @override
-  LabeledStatement visitLabeledStatement(LabeledStatement node) =>
-      new LabeledStatement(
-          cloneNodeList(node.labels), cloneNode(node.statement));
+  LabeledStatement visitLabeledStatement(LabeledStatement node) => astFactory
+      .labeledStatement(cloneNodeList(node.labels), cloneNode(node.statement));
 
   @override
   LibraryDirective visitLibraryDirective(LibraryDirective node) =>
-      new LibraryDirective(
+      astFactory.libraryDirective(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.libraryKeyword),
@@ -650,10 +654,10 @@
 
   @override
   LibraryIdentifier visitLibraryIdentifier(LibraryIdentifier node) =>
-      new LibraryIdentifier(cloneNodeList(node.components));
+      astFactory.libraryIdentifier(cloneNodeList(node.components));
 
   @override
-  ListLiteral visitListLiteral(ListLiteral node) => new ListLiteral(
+  ListLiteral visitListLiteral(ListLiteral node) => astFactory.listLiteral(
       cloneToken(node.constKeyword),
       cloneNode(node.typeArguments),
       cloneToken(node.leftBracket),
@@ -661,7 +665,7 @@
       cloneToken(node.rightBracket));
 
   @override
-  MapLiteral visitMapLiteral(MapLiteral node) => new MapLiteral(
+  MapLiteral visitMapLiteral(MapLiteral node) => astFactory.mapLiteral(
       cloneToken(node.constKeyword),
       cloneNode(node.typeArguments),
       cloneToken(node.leftBracket),
@@ -670,12 +674,12 @@
 
   @override
   MapLiteralEntry visitMapLiteralEntry(MapLiteralEntry node) =>
-      new MapLiteralEntry(cloneNode(node.key), cloneToken(node.separator),
-          cloneNode(node.value));
+      astFactory.mapLiteralEntry(cloneNode(node.key),
+          cloneToken(node.separator), cloneNode(node.value));
 
   @override
   MethodDeclaration visitMethodDeclaration(MethodDeclaration node) =>
-      new MethodDeclaration(
+      astFactory.methodDeclaration(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.externalKeyword),
@@ -690,7 +694,7 @@
 
   @override
   MethodInvocation visitMethodInvocation(MethodInvocation node) =>
-      new MethodInvocation(
+      astFactory.methodInvocation(
           cloneNode(node.target),
           cloneToken(node.operator),
           cloneNode(node.methodName),
@@ -698,31 +702,31 @@
           cloneNode(node.argumentList));
 
   @override
-  NamedExpression visitNamedExpression(NamedExpression node) =>
-      new NamedExpression(cloneNode(node.name), cloneNode(node.expression));
+  NamedExpression visitNamedExpression(NamedExpression node) => astFactory
+      .namedExpression(cloneNode(node.name), cloneNode(node.expression));
 
   @override
-  AstNode visitNativeClause(NativeClause node) =>
-      new NativeClause(cloneToken(node.nativeKeyword), cloneNode(node.name));
+  AstNode visitNativeClause(NativeClause node) => astFactory.nativeClause(
+      cloneToken(node.nativeKeyword), cloneNode(node.name));
 
   @override
   NativeFunctionBody visitNativeFunctionBody(NativeFunctionBody node) =>
-      new NativeFunctionBody(cloneToken(node.nativeKeyword),
+      astFactory.nativeFunctionBody(cloneToken(node.nativeKeyword),
           cloneNode(node.stringLiteral), cloneToken(node.semicolon));
 
   @override
   NullLiteral visitNullLiteral(NullLiteral node) =>
-      new NullLiteral(cloneToken(node.literal));
+      astFactory.nullLiteral(cloneToken(node.literal));
 
   @override
   ParenthesizedExpression visitParenthesizedExpression(
           ParenthesizedExpression node) =>
-      new ParenthesizedExpression(cloneToken(node.leftParenthesis),
+      astFactory.parenthesizedExpression(cloneToken(node.leftParenthesis),
           cloneNode(node.expression), cloneToken(node.rightParenthesis));
 
   @override
   PartDirective visitPartDirective(PartDirective node) {
-    PartDirective directive = new PartDirective(
+    PartDirective directive = astFactory.partDirective(
         cloneNode(node.documentationComment),
         cloneNodeList(node.metadata),
         cloneToken(node.partKeyword),
@@ -735,7 +739,7 @@
 
   @override
   PartOfDirective visitPartOfDirective(PartOfDirective node) =>
-      new PartOfDirective(
+      astFactory.partOfDirective(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.partKeyword),
@@ -745,28 +749,27 @@
           cloneToken(node.semicolon));
 
   @override
-  PostfixExpression visitPostfixExpression(PostfixExpression node) =>
-      new PostfixExpression(cloneNode(node.operand), cloneToken(node.operator));
+  PostfixExpression visitPostfixExpression(PostfixExpression node) => astFactory
+      .postfixExpression(cloneNode(node.operand), cloneToken(node.operator));
 
   @override
   PrefixedIdentifier visitPrefixedIdentifier(PrefixedIdentifier node) =>
-      new PrefixedIdentifier(cloneNode(node.prefix), cloneToken(node.period),
-          cloneNode(node.identifier));
+      astFactory.prefixedIdentifier(cloneNode(node.prefix),
+          cloneToken(node.period), cloneNode(node.identifier));
 
   @override
-  PrefixExpression visitPrefixExpression(PrefixExpression node) =>
-      new PrefixExpression(cloneToken(node.operator), cloneNode(node.operand));
+  PrefixExpression visitPrefixExpression(PrefixExpression node) => astFactory
+      .prefixExpression(cloneToken(node.operator), cloneNode(node.operand));
 
   @override
-  PropertyAccess visitPropertyAccess(PropertyAccess node) => new PropertyAccess(
-      cloneNode(node.target),
-      cloneToken(node.operator),
-      cloneNode(node.propertyName));
+  PropertyAccess visitPropertyAccess(PropertyAccess node) =>
+      astFactory.propertyAccess(cloneNode(node.target),
+          cloneToken(node.operator), cloneNode(node.propertyName));
 
   @override
   RedirectingConstructorInvocation visitRedirectingConstructorInvocation(
           RedirectingConstructorInvocation node) =>
-      new RedirectingConstructorInvocation(
+      astFactory.redirectingConstructorInvocation(
           cloneToken(node.thisKeyword),
           cloneToken(node.period),
           cloneNode(node.constructorName),
@@ -774,25 +777,25 @@
 
   @override
   RethrowExpression visitRethrowExpression(RethrowExpression node) =>
-      new RethrowExpression(cloneToken(node.rethrowKeyword));
+      astFactory.rethrowExpression(cloneToken(node.rethrowKeyword));
 
   @override
   ReturnStatement visitReturnStatement(ReturnStatement node) =>
-      new ReturnStatement(cloneToken(node.returnKeyword),
+      astFactory.returnStatement(cloneToken(node.returnKeyword),
           cloneNode(node.expression), cloneToken(node.semicolon));
 
   @override
   ScriptTag visitScriptTag(ScriptTag node) =>
-      new ScriptTag(cloneToken(node.scriptTag));
+      astFactory.scriptTag(cloneToken(node.scriptTag));
 
   @override
-  ShowCombinator visitShowCombinator(ShowCombinator node) => new ShowCombinator(
-      cloneToken(node.keyword), cloneNodeList(node.shownNames));
+  ShowCombinator visitShowCombinator(ShowCombinator node) => astFactory
+      .showCombinator(cloneToken(node.keyword), cloneNodeList(node.shownNames));
 
   @override
   SimpleFormalParameter visitSimpleFormalParameter(
           SimpleFormalParameter node) =>
-      new SimpleFormalParameter(
+      astFactory.simpleFormalParameter(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.keyword),
@@ -801,21 +804,21 @@
 
   @override
   SimpleIdentifier visitSimpleIdentifier(SimpleIdentifier node) =>
-      new SimpleIdentifier(cloneToken(node.token),
+      astFactory.simpleIdentifier(cloneToken(node.token),
           isDeclaration: node.inDeclarationContext());
 
   @override
   SimpleStringLiteral visitSimpleStringLiteral(SimpleStringLiteral node) =>
-      new SimpleStringLiteral(cloneToken(node.literal), node.value);
+      astFactory.simpleStringLiteral(cloneToken(node.literal), node.value);
 
   @override
   StringInterpolation visitStringInterpolation(StringInterpolation node) =>
-      new StringInterpolation(cloneNodeList(node.elements));
+      astFactory.stringInterpolation(cloneNodeList(node.elements));
 
   @override
   SuperConstructorInvocation visitSuperConstructorInvocation(
           SuperConstructorInvocation node) =>
-      new SuperConstructorInvocation(
+      astFactory.superConstructorInvocation(
           cloneToken(node.superKeyword),
           cloneToken(node.period),
           cloneNode(node.constructorName),
@@ -823,10 +826,10 @@
 
   @override
   SuperExpression visitSuperExpression(SuperExpression node) =>
-      new SuperExpression(cloneToken(node.superKeyword));
+      astFactory.superExpression(cloneToken(node.superKeyword));
 
   @override
-  SwitchCase visitSwitchCase(SwitchCase node) => new SwitchCase(
+  SwitchCase visitSwitchCase(SwitchCase node) => astFactory.switchCase(
       cloneNodeList(node.labels),
       cloneToken(node.keyword),
       cloneNode(node.expression),
@@ -834,15 +837,16 @@
       cloneNodeList(node.statements));
 
   @override
-  SwitchDefault visitSwitchDefault(SwitchDefault node) => new SwitchDefault(
-      cloneNodeList(node.labels),
-      cloneToken(node.keyword),
-      cloneToken(node.colon),
-      cloneNodeList(node.statements));
+  SwitchDefault visitSwitchDefault(SwitchDefault node) =>
+      astFactory.switchDefault(
+          cloneNodeList(node.labels),
+          cloneToken(node.keyword),
+          cloneToken(node.colon),
+          cloneNodeList(node.statements));
 
   @override
   SwitchStatement visitSwitchStatement(SwitchStatement node) =>
-      new SwitchStatement(
+      astFactory.switchStatement(
           cloneToken(node.switchKeyword),
           cloneToken(node.leftParenthesis),
           cloneNode(node.expression),
@@ -852,29 +856,30 @@
           cloneToken(node.rightBracket));
 
   @override
-  SymbolLiteral visitSymbolLiteral(SymbolLiteral node) => new SymbolLiteral(
-      cloneToken(node.poundSign), cloneTokenList(node.components));
+  SymbolLiteral visitSymbolLiteral(SymbolLiteral node) =>
+      astFactory.symbolLiteral(
+          cloneToken(node.poundSign), cloneTokenList(node.components));
 
   @override
   ThisExpression visitThisExpression(ThisExpression node) =>
-      new ThisExpression(cloneToken(node.thisKeyword));
+      astFactory.thisExpression(cloneToken(node.thisKeyword));
 
   @override
   ThrowExpression visitThrowExpression(ThrowExpression node) =>
-      new ThrowExpression(
+      astFactory.throwExpression(
           cloneToken(node.throwKeyword), cloneNode(node.expression));
 
   @override
   TopLevelVariableDeclaration visitTopLevelVariableDeclaration(
           TopLevelVariableDeclaration node) =>
-      new TopLevelVariableDeclaration(
+      astFactory.topLevelVariableDeclaration(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneNode(node.variables),
           cloneToken(node.semicolon));
 
   @override
-  TryStatement visitTryStatement(TryStatement node) => new TryStatement(
+  TryStatement visitTryStatement(TryStatement node) => astFactory.tryStatement(
       cloneToken(node.tryKeyword),
       cloneNode(node.body),
       cloneNodeList(node.catchClauses),
@@ -883,35 +888,36 @@
 
   @override
   TypeArgumentList visitTypeArgumentList(TypeArgumentList node) =>
-      new TypeArgumentList(cloneToken(node.leftBracket),
+      astFactory.typeArgumentList(cloneToken(node.leftBracket),
           cloneNodeList(node.arguments), cloneToken(node.rightBracket));
 
   @override
   TypeName visitTypeName(TypeName node) =>
-      new TypeName(cloneNode(node.name), cloneNode(node.typeArguments));
+      astFactory.typeName(cloneNode(node.name), cloneNode(node.typeArguments));
 
   @override
-  TypeParameter visitTypeParameter(TypeParameter node) => new TypeParameter(
-      cloneNode(node.documentationComment),
-      cloneNodeList(node.metadata),
-      cloneNode(node.name),
-      cloneToken(node.extendsKeyword),
-      cloneNode(node.bound));
+  TypeParameter visitTypeParameter(TypeParameter node) =>
+      astFactory.typeParameter(
+          cloneNode(node.documentationComment),
+          cloneNodeList(node.metadata),
+          cloneNode(node.name),
+          cloneToken(node.extendsKeyword),
+          cloneNode(node.bound));
 
   @override
   TypeParameterList visitTypeParameterList(TypeParameterList node) =>
-      new TypeParameterList(cloneToken(node.leftBracket),
+      astFactory.typeParameterList(cloneToken(node.leftBracket),
           cloneNodeList(node.typeParameters), cloneToken(node.rightBracket));
 
   @override
   VariableDeclaration visitVariableDeclaration(VariableDeclaration node) =>
-      new VariableDeclaration(cloneNode(node.name), cloneToken(node.equals),
-          cloneNode(node.initializer));
+      astFactory.variableDeclaration(cloneNode(node.name),
+          cloneToken(node.equals), cloneNode(node.initializer));
 
   @override
   VariableDeclarationList visitVariableDeclarationList(
           VariableDeclarationList node) =>
-      new VariableDeclarationList(
+      astFactory.variableDeclarationList(
           cloneNode(node.documentationComment),
           cloneNodeList(node.metadata),
           cloneToken(node.keyword),
@@ -921,27 +927,29 @@
   @override
   VariableDeclarationStatement visitVariableDeclarationStatement(
           VariableDeclarationStatement node) =>
-      new VariableDeclarationStatement(
+      astFactory.variableDeclarationStatement(
           cloneNode(node.variables), cloneToken(node.semicolon));
 
   @override
-  WhileStatement visitWhileStatement(WhileStatement node) => new WhileStatement(
-      cloneToken(node.whileKeyword),
-      cloneToken(node.leftParenthesis),
-      cloneNode(node.condition),
-      cloneToken(node.rightParenthesis),
-      cloneNode(node.body));
+  WhileStatement visitWhileStatement(WhileStatement node) =>
+      astFactory.whileStatement(
+          cloneToken(node.whileKeyword),
+          cloneToken(node.leftParenthesis),
+          cloneNode(node.condition),
+          cloneToken(node.rightParenthesis),
+          cloneNode(node.body));
 
   @override
-  WithClause visitWithClause(WithClause node) => new WithClause(
+  WithClause visitWithClause(WithClause node) => astFactory.withClause(
       cloneToken(node.withKeyword), cloneNodeList(node.mixinTypes));
 
   @override
-  YieldStatement visitYieldStatement(YieldStatement node) => new YieldStatement(
-      cloneToken(node.yieldKeyword),
-      cloneToken(node.star),
-      cloneNode(node.expression),
-      cloneToken(node.semicolon));
+  YieldStatement visitYieldStatement(YieldStatement node) =>
+      astFactory.yieldStatement(
+          cloneToken(node.yieldKeyword),
+          cloneToken(node.star),
+          cloneNode(node.expression),
+          cloneToken(node.semicolon));
 
   /**
    * Clone all token starting from the given [token] up to a token that has
@@ -2755,11 +2763,11 @@
 
   @override
   AdjacentStrings visitAdjacentStrings(AdjacentStrings node) =>
-      new AdjacentStrings(_cloneNodeList(node.strings));
+      astFactory.adjacentStrings(_cloneNodeList(node.strings));
 
   @override
   Annotation visitAnnotation(Annotation node) {
-    Annotation copy = new Annotation(
+    Annotation copy = astFactory.annotation(
         _mapToken(node.atSign),
         _cloneNode(node.name),
         _mapToken(node.period),
@@ -2770,14 +2778,14 @@
   }
 
   @override
-  ArgumentList visitArgumentList(ArgumentList node) => new ArgumentList(
+  ArgumentList visitArgumentList(ArgumentList node) => astFactory.argumentList(
       _mapToken(node.leftParenthesis),
       _cloneNodeList(node.arguments),
       _mapToken(node.rightParenthesis));
 
   @override
   AsExpression visitAsExpression(AsExpression node) {
-    AsExpression copy = new AsExpression(_cloneNode(node.expression),
+    AsExpression copy = astFactory.asExpression(_cloneNode(node.expression),
         _mapToken(node.asOperator), _cloneNode(node.type));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
@@ -2786,7 +2794,7 @@
 
   @override
   AstNode visitAssertInitializer(AssertInitializer node) =>
-      new AssertInitializer(
+      astFactory.assertInitializer(
           _mapToken(node.assertKeyword),
           _mapToken(node.leftParenthesis),
           _cloneNode(node.condition),
@@ -2795,18 +2803,19 @@
           _mapToken(node.rightParenthesis));
 
   @override
-  AstNode visitAssertStatement(AssertStatement node) => new AssertStatement(
-      _mapToken(node.assertKeyword),
-      _mapToken(node.leftParenthesis),
-      _cloneNode(node.condition),
-      _mapToken(node.comma),
-      _cloneNode(node.message),
-      _mapToken(node.rightParenthesis),
-      _mapToken(node.semicolon));
+  AstNode visitAssertStatement(AssertStatement node) =>
+      astFactory.assertStatement(
+          _mapToken(node.assertKeyword),
+          _mapToken(node.leftParenthesis),
+          _cloneNode(node.condition),
+          _mapToken(node.comma),
+          _cloneNode(node.message),
+          _mapToken(node.rightParenthesis),
+          _mapToken(node.semicolon));
 
   @override
   AssignmentExpression visitAssignmentExpression(AssignmentExpression node) {
-    AssignmentExpression copy = new AssignmentExpression(
+    AssignmentExpression copy = astFactory.assignmentExpression(
         _cloneNode(node.leftHandSide),
         _mapToken(node.operator),
         _cloneNode(node.rightHandSide));
@@ -2819,13 +2828,15 @@
 
   @override
   AwaitExpression visitAwaitExpression(AwaitExpression node) =>
-      new AwaitExpression(
+      astFactory.awaitExpression(
           _mapToken(node.awaitKeyword), _cloneNode(node.expression));
 
   @override
   BinaryExpression visitBinaryExpression(BinaryExpression node) {
-    BinaryExpression copy = new BinaryExpression(_cloneNode(node.leftOperand),
-        _mapToken(node.operator), _cloneNode(node.rightOperand));
+    BinaryExpression copy = astFactory.binaryExpression(
+        _cloneNode(node.leftOperand),
+        _mapToken(node.operator),
+        _cloneNode(node.rightOperand));
     copy.propagatedElement = node.propagatedElement;
     copy.propagatedType = node.propagatedType;
     copy.staticElement = node.staticElement;
@@ -2834,32 +2845,31 @@
   }
 
   @override
-  Block visitBlock(Block node) => new Block(_mapToken(node.leftBracket),
+  Block visitBlock(Block node) => astFactory.block(_mapToken(node.leftBracket),
       _cloneNodeList(node.statements), _mapToken(node.rightBracket));
 
   @override
   BlockFunctionBody visitBlockFunctionBody(BlockFunctionBody node) =>
-      new BlockFunctionBody(_mapToken(node.keyword), _mapToken(node.star),
-          _cloneNode(node.block));
+      astFactory.blockFunctionBody(_mapToken(node.keyword),
+          _mapToken(node.star), _cloneNode(node.block));
 
   @override
   BooleanLiteral visitBooleanLiteral(BooleanLiteral node) {
     BooleanLiteral copy =
-        new BooleanLiteral(_mapToken(node.literal), node.value);
+        astFactory.booleanLiteral(_mapToken(node.literal), node.value);
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
   }
 
   @override
-  BreakStatement visitBreakStatement(BreakStatement node) => new BreakStatement(
-      _mapToken(node.breakKeyword),
-      _cloneNode(node.label),
-      _mapToken(node.semicolon));
+  BreakStatement visitBreakStatement(BreakStatement node) =>
+      astFactory.breakStatement(_mapToken(node.breakKeyword),
+          _cloneNode(node.label), _mapToken(node.semicolon));
 
   @override
   CascadeExpression visitCascadeExpression(CascadeExpression node) {
-    CascadeExpression copy = new CascadeExpression(
+    CascadeExpression copy = astFactory.cascadeExpression(
         _cloneNode(node.target), _cloneNodeList(node.cascadeSections));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
@@ -2867,7 +2877,7 @@
   }
 
   @override
-  CatchClause visitCatchClause(CatchClause node) => new CatchClause(
+  CatchClause visitCatchClause(CatchClause node) => astFactory.catchClause(
       _mapToken(node.onKeyword),
       _cloneNode(node.exceptionType),
       _mapToken(node.catchKeyword),
@@ -2880,7 +2890,7 @@
 
   @override
   ClassDeclaration visitClassDeclaration(ClassDeclaration node) {
-    ClassDeclaration copy = new ClassDeclaration(
+    ClassDeclaration copy = astFactory.classDeclaration(
         _cloneNode(node.documentationComment),
         _cloneNodeList(node.metadata),
         _mapToken(node.abstractKeyword),
@@ -2898,38 +2908,39 @@
   }
 
   @override
-  ClassTypeAlias visitClassTypeAlias(ClassTypeAlias node) => new ClassTypeAlias(
-      _cloneNode(node.documentationComment),
-      _cloneNodeList(node.metadata),
-      _mapToken(node.typedefKeyword),
-      _cloneNode(node.name),
-      _cloneNode(node.typeParameters),
-      _mapToken(node.equals),
-      _mapToken(node.abstractKeyword),
-      _cloneNode(node.superclass),
-      _cloneNode(node.withClause),
-      _cloneNode(node.implementsClause),
-      _mapToken(node.semicolon));
+  ClassTypeAlias visitClassTypeAlias(ClassTypeAlias node) =>
+      astFactory.classTypeAlias(
+          _cloneNode(node.documentationComment),
+          _cloneNodeList(node.metadata),
+          _mapToken(node.typedefKeyword),
+          _cloneNode(node.name),
+          _cloneNode(node.typeParameters),
+          _mapToken(node.equals),
+          _mapToken(node.abstractKeyword),
+          _cloneNode(node.superclass),
+          _cloneNode(node.withClause),
+          _cloneNode(node.implementsClause),
+          _mapToken(node.semicolon));
 
   @override
   Comment visitComment(Comment node) {
     if (node.isDocumentation) {
-      return Comment.createDocumentationCommentWithReferences(
+      return astFactory.documentationComment(
           _mapTokens(node.tokens), _cloneNodeList(node.references));
     } else if (node.isBlock) {
-      return Comment.createBlockComment(_mapTokens(node.tokens));
+      return astFactory.blockComment(_mapTokens(node.tokens));
     }
-    return Comment.createEndOfLineComment(_mapTokens(node.tokens));
+    return astFactory.endOfLineComment(_mapTokens(node.tokens));
   }
 
   @override
   CommentReference visitCommentReference(CommentReference node) =>
-      new CommentReference(
+      astFactory.commentReference(
           _mapToken(node.newKeyword), _cloneNode(node.identifier));
 
   @override
   CompilationUnit visitCompilationUnit(CompilationUnit node) {
-    CompilationUnit copy = new CompilationUnit(
+    CompilationUnit copy = astFactory.compilationUnit(
         _mapToken(node.beginToken),
         _cloneNode(node.scriptTag),
         _cloneNodeList(node.directives),
@@ -2942,7 +2953,7 @@
 
   @override
   ConditionalExpression visitConditionalExpression(ConditionalExpression node) {
-    ConditionalExpression copy = new ConditionalExpression(
+    ConditionalExpression copy = astFactory.conditionalExpression(
         _cloneNode(node.condition),
         _mapToken(node.question),
         _cloneNode(node.thenExpression),
@@ -2954,19 +2965,20 @@
   }
 
   @override
-  Configuration visitConfiguration(Configuration node) => new Configuration(
-      _mapToken(node.ifKeyword),
-      _mapToken(node.leftParenthesis),
-      _cloneNode(node.name),
-      _mapToken(node.equalToken),
-      _cloneNode(node.value),
-      _mapToken(node.rightParenthesis),
-      _cloneNode(node.uri));
+  Configuration visitConfiguration(Configuration node) =>
+      astFactory.configuration(
+          _mapToken(node.ifKeyword),
+          _mapToken(node.leftParenthesis),
+          _cloneNode(node.name),
+          _mapToken(node.equalToken),
+          _cloneNode(node.value),
+          _mapToken(node.rightParenthesis),
+          _cloneNode(node.uri));
 
   @override
   ConstructorDeclaration visitConstructorDeclaration(
       ConstructorDeclaration node) {
-    ConstructorDeclaration copy = new ConstructorDeclaration(
+    ConstructorDeclaration copy = astFactory.constructorDeclaration(
         _cloneNode(node.documentationComment),
         _cloneNodeList(node.metadata),
         _mapToken(node.externalKeyword),
@@ -2987,7 +2999,7 @@
   @override
   ConstructorFieldInitializer visitConstructorFieldInitializer(
           ConstructorFieldInitializer node) =>
-      new ConstructorFieldInitializer(
+      astFactory.constructorFieldInitializer(
           _mapToken(node.thisKeyword),
           _mapToken(node.period),
           _cloneNode(node.fieldName),
@@ -2996,7 +3008,7 @@
 
   @override
   ConstructorName visitConstructorName(ConstructorName node) {
-    ConstructorName copy = new ConstructorName(
+    ConstructorName copy = astFactory.constructorName(
         _cloneNode(node.type), _mapToken(node.period), _cloneNode(node.name));
     copy.staticElement = node.staticElement;
     return copy;
@@ -3004,12 +3016,12 @@
 
   @override
   ContinueStatement visitContinueStatement(ContinueStatement node) =>
-      new ContinueStatement(_mapToken(node.continueKeyword),
+      astFactory.continueStatement(_mapToken(node.continueKeyword),
           _cloneNode(node.label), _mapToken(node.semicolon));
 
   @override
   DeclaredIdentifier visitDeclaredIdentifier(DeclaredIdentifier node) =>
-      new DeclaredIdentifier(
+      astFactory.declaredIdentifier(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _mapToken(node.keyword),
@@ -3019,11 +3031,11 @@
   @override
   DefaultFormalParameter visitDefaultFormalParameter(
           DefaultFormalParameter node) =>
-      new DefaultFormalParameter(_cloneNode(node.parameter), node.kind,
+      astFactory.defaultFormalParameter(_cloneNode(node.parameter), node.kind,
           _mapToken(node.separator), _cloneNode(node.defaultValue));
 
   @override
-  DoStatement visitDoStatement(DoStatement node) => new DoStatement(
+  DoStatement visitDoStatement(DoStatement node) => astFactory.doStatement(
       _mapToken(node.doKeyword),
       _cloneNode(node.body),
       _mapToken(node.whileKeyword),
@@ -3034,11 +3046,12 @@
 
   @override
   DottedName visitDottedName(DottedName node) =>
-      new DottedName(_cloneNodeList(node.components));
+      astFactory.dottedName(_cloneNodeList(node.components));
 
   @override
   DoubleLiteral visitDoubleLiteral(DoubleLiteral node) {
-    DoubleLiteral copy = new DoubleLiteral(_mapToken(node.literal), node.value);
+    DoubleLiteral copy =
+        astFactory.doubleLiteral(_mapToken(node.literal), node.value);
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3046,30 +3059,31 @@
 
   @override
   EmptyFunctionBody visitEmptyFunctionBody(EmptyFunctionBody node) =>
-      new EmptyFunctionBody(_mapToken(node.semicolon));
+      astFactory.emptyFunctionBody(_mapToken(node.semicolon));
 
   @override
   EmptyStatement visitEmptyStatement(EmptyStatement node) =>
-      new EmptyStatement(_mapToken(node.semicolon));
+      astFactory.emptyStatement(_mapToken(node.semicolon));
 
   @override
   AstNode visitEnumConstantDeclaration(EnumConstantDeclaration node) =>
-      new EnumConstantDeclaration(_cloneNode(node.documentationComment),
+      astFactory.enumConstantDeclaration(_cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata), _cloneNode(node.name));
 
   @override
-  AstNode visitEnumDeclaration(EnumDeclaration node) => new EnumDeclaration(
-      _cloneNode(node.documentationComment),
-      _cloneNodeList(node.metadata),
-      _mapToken(node.enumKeyword),
-      _cloneNode(node.name),
-      _mapToken(node.leftBracket),
-      _cloneNodeList(node.constants),
-      _mapToken(node.rightBracket));
+  AstNode visitEnumDeclaration(EnumDeclaration node) =>
+      astFactory.enumDeclaration(
+          _cloneNode(node.documentationComment),
+          _cloneNodeList(node.metadata),
+          _mapToken(node.enumKeyword),
+          _cloneNode(node.name),
+          _mapToken(node.leftBracket),
+          _cloneNodeList(node.constants),
+          _mapToken(node.rightBracket));
 
   @override
   ExportDirective visitExportDirective(ExportDirective node) {
-    ExportDirective copy = new ExportDirective(
+    ExportDirective copy = astFactory.exportDirective(
         _cloneNode(node.documentationComment),
         _cloneNodeList(node.metadata),
         _mapToken(node.keyword),
@@ -3084,7 +3098,7 @@
   @override
   ExpressionFunctionBody visitExpressionFunctionBody(
           ExpressionFunctionBody node) =>
-      new ExpressionFunctionBody(
+      astFactory.expressionFunctionBody(
           _mapToken(node.keyword),
           _mapToken(node.functionDefinition),
           _cloneNode(node.expression),
@@ -3092,16 +3106,17 @@
 
   @override
   ExpressionStatement visitExpressionStatement(ExpressionStatement node) =>
-      new ExpressionStatement(
+      astFactory.expressionStatement(
           _cloneNode(node.expression), _mapToken(node.semicolon));
 
   @override
-  ExtendsClause visitExtendsClause(ExtendsClause node) => new ExtendsClause(
-      _mapToken(node.extendsKeyword), _cloneNode(node.superclass));
+  ExtendsClause visitExtendsClause(ExtendsClause node) =>
+      astFactory.extendsClause(
+          _mapToken(node.extendsKeyword), _cloneNode(node.superclass));
 
   @override
   FieldDeclaration visitFieldDeclaration(FieldDeclaration node) =>
-      new FieldDeclaration(
+      astFactory.fieldDeclaration(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _mapToken(node.staticKeyword),
@@ -3110,7 +3125,7 @@
 
   @override
   FieldFormalParameter visitFieldFormalParameter(FieldFormalParameter node) =>
-      new FieldFormalParameter(
+      astFactory.fieldFormalParameter(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _mapToken(node.keyword),
@@ -3125,7 +3140,7 @@
   ForEachStatement visitForEachStatement(ForEachStatement node) {
     DeclaredIdentifier loopVariable = node.loopVariable;
     if (loopVariable == null) {
-      return new ForEachStatement.withReference(
+      return astFactory.forEachStatementWithReference(
           _mapToken(node.awaitKeyword),
           _mapToken(node.forKeyword),
           _mapToken(node.leftParenthesis),
@@ -3135,7 +3150,7 @@
           _mapToken(node.rightParenthesis),
           _cloneNode(node.body));
     }
-    return new ForEachStatement.withDeclaration(
+    return astFactory.forEachStatementWithDeclaration(
         _mapToken(node.awaitKeyword),
         _mapToken(node.forKeyword),
         _mapToken(node.leftParenthesis),
@@ -3148,7 +3163,7 @@
 
   @override
   FormalParameterList visitFormalParameterList(FormalParameterList node) =>
-      new FormalParameterList(
+      astFactory.formalParameterList(
           _mapToken(node.leftParenthesis),
           _cloneNodeList(node.parameters),
           _mapToken(node.leftDelimiter),
@@ -3156,7 +3171,7 @@
           _mapToken(node.rightParenthesis));
 
   @override
-  ForStatement visitForStatement(ForStatement node) => new ForStatement(
+  ForStatement visitForStatement(ForStatement node) => astFactory.forStatement(
       _mapToken(node.forKeyword),
       _mapToken(node.leftParenthesis),
       _cloneNode(node.variables),
@@ -3170,7 +3185,7 @@
 
   @override
   FunctionDeclaration visitFunctionDeclaration(FunctionDeclaration node) =>
-      new FunctionDeclaration(
+      astFactory.functionDeclaration(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _mapToken(node.externalKeyword),
@@ -3182,11 +3197,12 @@
   @override
   FunctionDeclarationStatement visitFunctionDeclarationStatement(
           FunctionDeclarationStatement node) =>
-      new FunctionDeclarationStatement(_cloneNode(node.functionDeclaration));
+      astFactory
+          .functionDeclarationStatement(_cloneNode(node.functionDeclaration));
 
   @override
   FunctionExpression visitFunctionExpression(FunctionExpression node) {
-    FunctionExpression copy = new FunctionExpression(
+    FunctionExpression copy = astFactory.functionExpression(
         _cloneNode(node.typeParameters),
         _cloneNode(node.parameters),
         _cloneNode(node.body));
@@ -3199,7 +3215,7 @@
   @override
   FunctionExpressionInvocation visitFunctionExpressionInvocation(
       FunctionExpressionInvocation node) {
-    FunctionExpressionInvocation copy = new FunctionExpressionInvocation(
+    FunctionExpressionInvocation copy = astFactory.functionExpressionInvocation(
         _cloneNode(node.function),
         _cloneNode(node.typeArguments),
         _cloneNode(node.argumentList));
@@ -3212,7 +3228,7 @@
 
   @override
   FunctionTypeAlias visitFunctionTypeAlias(FunctionTypeAlias node) =>
-      new FunctionTypeAlias(
+      astFactory.functionTypeAlias(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _mapToken(node.typedefKeyword),
@@ -3225,7 +3241,7 @@
   @override
   FunctionTypedFormalParameter visitFunctionTypedFormalParameter(
           FunctionTypedFormalParameter node) =>
-      new FunctionTypedFormalParameter(
+      astFactory.functionTypedFormalParameter(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _cloneNode(node.returnType),
@@ -3234,11 +3250,12 @@
           _cloneNode(node.parameters));
 
   @override
-  HideCombinator visitHideCombinator(HideCombinator node) => new HideCombinator(
-      _mapToken(node.keyword), _cloneNodeList(node.hiddenNames));
+  HideCombinator visitHideCombinator(HideCombinator node) =>
+      astFactory.hideCombinator(
+          _mapToken(node.keyword), _cloneNodeList(node.hiddenNames));
 
   @override
-  IfStatement visitIfStatement(IfStatement node) => new IfStatement(
+  IfStatement visitIfStatement(IfStatement node) => astFactory.ifStatement(
       _mapToken(node.ifKeyword),
       _mapToken(node.leftParenthesis),
       _cloneNode(node.condition),
@@ -3249,12 +3266,12 @@
 
   @override
   ImplementsClause visitImplementsClause(ImplementsClause node) =>
-      new ImplementsClause(
+      astFactory.implementsClause(
           _mapToken(node.implementsKeyword), _cloneNodeList(node.interfaces));
 
   @override
   ImportDirective visitImportDirective(ImportDirective node) {
-    ImportDirective copy = new ImportDirective(
+    ImportDirective copy = astFactory.importDirective(
         _cloneNode(node.documentationComment),
         _cloneNodeList(node.metadata),
         _mapToken(node.keyword),
@@ -3274,14 +3291,17 @@
     Token period = _mapToken(node.period);
     IndexExpression copy;
     if (period == null) {
-      copy = new IndexExpression.forTarget(
+      copy = astFactory.indexExpressionForTarget(
           _cloneNode(node.target),
           _mapToken(node.leftBracket),
           _cloneNode(node.index),
           _mapToken(node.rightBracket));
     } else {
-      copy = new IndexExpression.forCascade(period, _mapToken(node.leftBracket),
-          _cloneNode(node.index), _mapToken(node.rightBracket));
+      copy = astFactory.indexExpressionForCascade(
+          period,
+          _mapToken(node.leftBracket),
+          _cloneNode(node.index),
+          _mapToken(node.rightBracket));
     }
     copy.auxiliaryElements = node.auxiliaryElements;
     copy.propagatedElement = node.propagatedElement;
@@ -3294,7 +3314,7 @@
   @override
   InstanceCreationExpression visitInstanceCreationExpression(
       InstanceCreationExpression node) {
-    InstanceCreationExpression copy = new InstanceCreationExpression(
+    InstanceCreationExpression copy = astFactory.instanceCreationExpression(
         _mapToken(node.keyword),
         _cloneNode(node.constructorName),
         _cloneNode(node.argumentList));
@@ -3307,7 +3327,7 @@
   @override
   IntegerLiteral visitIntegerLiteral(IntegerLiteral node) {
     IntegerLiteral copy =
-        new IntegerLiteral(_mapToken(node.literal), node.value);
+        astFactory.integerLiteral(_mapToken(node.literal), node.value);
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3316,16 +3336,16 @@
   @override
   InterpolationExpression visitInterpolationExpression(
           InterpolationExpression node) =>
-      new InterpolationExpression(_mapToken(node.leftBracket),
+      astFactory.interpolationExpression(_mapToken(node.leftBracket),
           _cloneNode(node.expression), _mapToken(node.rightBracket));
 
   @override
   InterpolationString visitInterpolationString(InterpolationString node) =>
-      new InterpolationString(_mapToken(node.contents), node.value);
+      astFactory.interpolationString(_mapToken(node.contents), node.value);
 
   @override
   IsExpression visitIsExpression(IsExpression node) {
-    IsExpression copy = new IsExpression(
+    IsExpression copy = astFactory.isExpression(
         _cloneNode(node.expression),
         _mapToken(node.isOperator),
         _mapToken(node.notOperator),
@@ -3337,16 +3357,16 @@
 
   @override
   Label visitLabel(Label node) =>
-      new Label(_cloneNode(node.label), _mapToken(node.colon));
+      astFactory.label(_cloneNode(node.label), _mapToken(node.colon));
 
   @override
   LabeledStatement visitLabeledStatement(LabeledStatement node) =>
-      new LabeledStatement(
+      astFactory.labeledStatement(
           _cloneNodeList(node.labels), _cloneNode(node.statement));
 
   @override
   LibraryDirective visitLibraryDirective(LibraryDirective node) {
-    LibraryDirective copy = new LibraryDirective(
+    LibraryDirective copy = astFactory.libraryDirective(
         _cloneNode(node.documentationComment),
         _cloneNodeList(node.metadata),
         _mapToken(node.libraryKeyword),
@@ -3359,7 +3379,7 @@
   @override
   LibraryIdentifier visitLibraryIdentifier(LibraryIdentifier node) {
     LibraryIdentifier copy =
-        new LibraryIdentifier(_cloneNodeList(node.components));
+        astFactory.libraryIdentifier(_cloneNodeList(node.components));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3367,7 +3387,7 @@
 
   @override
   ListLiteral visitListLiteral(ListLiteral node) {
-    ListLiteral copy = new ListLiteral(
+    ListLiteral copy = astFactory.listLiteral(
         _mapToken(node.constKeyword),
         _cloneNode(node.typeArguments),
         _mapToken(node.leftBracket),
@@ -3380,7 +3400,7 @@
 
   @override
   MapLiteral visitMapLiteral(MapLiteral node) {
-    MapLiteral copy = new MapLiteral(
+    MapLiteral copy = astFactory.mapLiteral(
         _mapToken(node.constKeyword),
         _cloneNode(node.typeArguments),
         _mapToken(node.leftBracket),
@@ -3393,12 +3413,12 @@
 
   @override
   MapLiteralEntry visitMapLiteralEntry(MapLiteralEntry node) =>
-      new MapLiteralEntry(_cloneNode(node.key), _mapToken(node.separator),
-          _cloneNode(node.value));
+      astFactory.mapLiteralEntry(_cloneNode(node.key),
+          _mapToken(node.separator), _cloneNode(node.value));
 
   @override
   MethodDeclaration visitMethodDeclaration(MethodDeclaration node) =>
-      new MethodDeclaration(
+      astFactory.methodDeclaration(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _mapToken(node.externalKeyword),
@@ -3413,7 +3433,7 @@
 
   @override
   MethodInvocation visitMethodInvocation(MethodInvocation node) {
-    MethodInvocation copy = new MethodInvocation(
+    MethodInvocation copy = astFactory.methodInvocation(
         _cloneNode(node.target),
         _mapToken(node.operator),
         _cloneNode(node.methodName),
@@ -3426,25 +3446,25 @@
 
   @override
   NamedExpression visitNamedExpression(NamedExpression node) {
-    NamedExpression copy =
-        new NamedExpression(_cloneNode(node.name), _cloneNode(node.expression));
+    NamedExpression copy = astFactory.namedExpression(
+        _cloneNode(node.name), _cloneNode(node.expression));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
   }
 
   @override
-  AstNode visitNativeClause(NativeClause node) =>
-      new NativeClause(_mapToken(node.nativeKeyword), _cloneNode(node.name));
+  AstNode visitNativeClause(NativeClause node) => astFactory.nativeClause(
+      _mapToken(node.nativeKeyword), _cloneNode(node.name));
 
   @override
   NativeFunctionBody visitNativeFunctionBody(NativeFunctionBody node) =>
-      new NativeFunctionBody(_mapToken(node.nativeKeyword),
+      astFactory.nativeFunctionBody(_mapToken(node.nativeKeyword),
           _cloneNode(node.stringLiteral), _mapToken(node.semicolon));
 
   @override
   NullLiteral visitNullLiteral(NullLiteral node) {
-    NullLiteral copy = new NullLiteral(_mapToken(node.literal));
+    NullLiteral copy = astFactory.nullLiteral(_mapToken(node.literal));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3453,7 +3473,7 @@
   @override
   ParenthesizedExpression visitParenthesizedExpression(
       ParenthesizedExpression node) {
-    ParenthesizedExpression copy = new ParenthesizedExpression(
+    ParenthesizedExpression copy = astFactory.parenthesizedExpression(
         _mapToken(node.leftParenthesis),
         _cloneNode(node.expression),
         _mapToken(node.rightParenthesis));
@@ -3464,7 +3484,7 @@
 
   @override
   PartDirective visitPartDirective(PartDirective node) {
-    PartDirective copy = new PartDirective(
+    PartDirective copy = astFactory.partDirective(
         _cloneNode(node.documentationComment),
         _cloneNodeList(node.metadata),
         _mapToken(node.partKeyword),
@@ -3476,7 +3496,7 @@
 
   @override
   PartOfDirective visitPartOfDirective(PartOfDirective node) {
-    PartOfDirective copy = new PartOfDirective(
+    PartOfDirective copy = astFactory.partOfDirective(
         _cloneNode(node.documentationComment),
         _cloneNodeList(node.metadata),
         _mapToken(node.partKeyword),
@@ -3490,7 +3510,7 @@
 
   @override
   PostfixExpression visitPostfixExpression(PostfixExpression node) {
-    PostfixExpression copy = new PostfixExpression(
+    PostfixExpression copy = astFactory.postfixExpression(
         _cloneNode(node.operand), _mapToken(node.operator));
     copy.propagatedElement = node.propagatedElement;
     copy.propagatedType = node.propagatedType;
@@ -3501,8 +3521,10 @@
 
   @override
   PrefixedIdentifier visitPrefixedIdentifier(PrefixedIdentifier node) {
-    PrefixedIdentifier copy = new PrefixedIdentifier(_cloneNode(node.prefix),
-        _mapToken(node.period), _cloneNode(node.identifier));
+    PrefixedIdentifier copy = astFactory.prefixedIdentifier(
+        _cloneNode(node.prefix),
+        _mapToken(node.period),
+        _cloneNode(node.identifier));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3510,7 +3532,7 @@
 
   @override
   PrefixExpression visitPrefixExpression(PrefixExpression node) {
-    PrefixExpression copy = new PrefixExpression(
+    PrefixExpression copy = astFactory.prefixExpression(
         _mapToken(node.operator), _cloneNode(node.operand));
     copy.propagatedElement = node.propagatedElement;
     copy.propagatedType = node.propagatedType;
@@ -3521,7 +3543,7 @@
 
   @override
   PropertyAccess visitPropertyAccess(PropertyAccess node) {
-    PropertyAccess copy = new PropertyAccess(_cloneNode(node.target),
+    PropertyAccess copy = astFactory.propertyAccess(_cloneNode(node.target),
         _mapToken(node.operator), _cloneNode(node.propertyName));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
@@ -3532,7 +3554,7 @@
   RedirectingConstructorInvocation visitRedirectingConstructorInvocation(
       RedirectingConstructorInvocation node) {
     RedirectingConstructorInvocation copy =
-        new RedirectingConstructorInvocation(
+        astFactory.redirectingConstructorInvocation(
             _mapToken(node.thisKeyword),
             _mapToken(node.period),
             _cloneNode(node.constructorName),
@@ -3544,7 +3566,7 @@
   @override
   RethrowExpression visitRethrowExpression(RethrowExpression node) {
     RethrowExpression copy =
-        new RethrowExpression(_mapToken(node.rethrowKeyword));
+        astFactory.rethrowExpression(_mapToken(node.rethrowKeyword));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3552,21 +3574,21 @@
 
   @override
   ReturnStatement visitReturnStatement(ReturnStatement node) =>
-      new ReturnStatement(_mapToken(node.returnKeyword),
+      astFactory.returnStatement(_mapToken(node.returnKeyword),
           _cloneNode(node.expression), _mapToken(node.semicolon));
 
   @override
   ScriptTag visitScriptTag(ScriptTag node) =>
-      new ScriptTag(_mapToken(node.scriptTag));
+      astFactory.scriptTag(_mapToken(node.scriptTag));
 
   @override
-  ShowCombinator visitShowCombinator(ShowCombinator node) => new ShowCombinator(
-      _mapToken(node.keyword), _cloneNodeList(node.shownNames));
+  ShowCombinator visitShowCombinator(ShowCombinator node) => astFactory
+      .showCombinator(_mapToken(node.keyword), _cloneNodeList(node.shownNames));
 
   @override
   SimpleFormalParameter visitSimpleFormalParameter(
           SimpleFormalParameter node) =>
-      new SimpleFormalParameter(
+      astFactory.simpleFormalParameter(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _mapToken(node.keyword),
@@ -3584,7 +3606,7 @@
       // documentation comments for the parser.
       mappedToken = node.token;
     }
-    SimpleIdentifier copy = new SimpleIdentifier(mappedToken,
+    SimpleIdentifier copy = astFactory.simpleIdentifier(mappedToken,
         isDeclaration: node.inDeclarationContext());
     copy.auxiliaryElements = node.auxiliaryElements;
     copy.propagatedElement = node.propagatedElement;
@@ -3597,7 +3619,7 @@
   @override
   SimpleStringLiteral visitSimpleStringLiteral(SimpleStringLiteral node) {
     SimpleStringLiteral copy =
-        new SimpleStringLiteral(_mapToken(node.literal), node.value);
+        astFactory.simpleStringLiteral(_mapToken(node.literal), node.value);
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3606,7 +3628,7 @@
   @override
   StringInterpolation visitStringInterpolation(StringInterpolation node) {
     StringInterpolation copy =
-        new StringInterpolation(_cloneNodeList(node.elements));
+        astFactory.stringInterpolation(_cloneNodeList(node.elements));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3615,7 +3637,7 @@
   @override
   SuperConstructorInvocation visitSuperConstructorInvocation(
       SuperConstructorInvocation node) {
-    SuperConstructorInvocation copy = new SuperConstructorInvocation(
+    SuperConstructorInvocation copy = astFactory.superConstructorInvocation(
         _mapToken(node.superKeyword),
         _mapToken(node.period),
         _cloneNode(node.constructorName),
@@ -3626,14 +3648,15 @@
 
   @override
   SuperExpression visitSuperExpression(SuperExpression node) {
-    SuperExpression copy = new SuperExpression(_mapToken(node.superKeyword));
+    SuperExpression copy =
+        astFactory.superExpression(_mapToken(node.superKeyword));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
   }
 
   @override
-  SwitchCase visitSwitchCase(SwitchCase node) => new SwitchCase(
+  SwitchCase visitSwitchCase(SwitchCase node) => astFactory.switchCase(
       _cloneNodeList(node.labels),
       _mapToken(node.keyword),
       _cloneNode(node.expression),
@@ -3641,15 +3664,16 @@
       _cloneNodeList(node.statements));
 
   @override
-  SwitchDefault visitSwitchDefault(SwitchDefault node) => new SwitchDefault(
-      _cloneNodeList(node.labels),
-      _mapToken(node.keyword),
-      _mapToken(node.colon),
-      _cloneNodeList(node.statements));
+  SwitchDefault visitSwitchDefault(SwitchDefault node) =>
+      astFactory.switchDefault(
+          _cloneNodeList(node.labels),
+          _mapToken(node.keyword),
+          _mapToken(node.colon),
+          _cloneNodeList(node.statements));
 
   @override
   SwitchStatement visitSwitchStatement(SwitchStatement node) =>
-      new SwitchStatement(
+      astFactory.switchStatement(
           _mapToken(node.switchKeyword),
           _mapToken(node.leftParenthesis),
           _cloneNode(node.expression),
@@ -3660,7 +3684,7 @@
 
   @override
   AstNode visitSymbolLiteral(SymbolLiteral node) {
-    SymbolLiteral copy = new SymbolLiteral(
+    SymbolLiteral copy = astFactory.symbolLiteral(
         _mapToken(node.poundSign), _mapTokens(node.components));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
@@ -3669,7 +3693,8 @@
 
   @override
   ThisExpression visitThisExpression(ThisExpression node) {
-    ThisExpression copy = new ThisExpression(_mapToken(node.thisKeyword));
+    ThisExpression copy =
+        astFactory.thisExpression(_mapToken(node.thisKeyword));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
     return copy;
@@ -3677,7 +3702,7 @@
 
   @override
   ThrowExpression visitThrowExpression(ThrowExpression node) {
-    ThrowExpression copy = new ThrowExpression(
+    ThrowExpression copy = astFactory.throwExpression(
         _mapToken(node.throwKeyword), _cloneNode(node.expression));
     copy.propagatedType = node.propagatedType;
     copy.staticType = node.staticType;
@@ -3687,14 +3712,14 @@
   @override
   TopLevelVariableDeclaration visitTopLevelVariableDeclaration(
           TopLevelVariableDeclaration node) =>
-      new TopLevelVariableDeclaration(
+      astFactory.topLevelVariableDeclaration(
           _cloneNode(node.documentationComment),
           _cloneNodeList(node.metadata),
           _cloneNode(node.variables),
           _mapToken(node.semicolon));
 
   @override
-  TryStatement visitTryStatement(TryStatement node) => new TryStatement(
+  TryStatement visitTryStatement(TryStatement node) => astFactory.tryStatement(
       _mapToken(node.tryKeyword),
       _cloneNode(node.body),
       _cloneNodeList(node.catchClauses),
@@ -3703,39 +3728,40 @@
 
   @override
   TypeArgumentList visitTypeArgumentList(TypeArgumentList node) =>
-      new TypeArgumentList(_mapToken(node.leftBracket),
+      astFactory.typeArgumentList(_mapToken(node.leftBracket),
           _cloneNodeList(node.arguments), _mapToken(node.rightBracket));
 
   @override
   TypeName visitTypeName(TypeName node) {
-    TypeName copy =
-        new TypeName(_cloneNode(node.name), _cloneNode(node.typeArguments));
+    TypeName copy = astFactory.typeName(
+        _cloneNode(node.name), _cloneNode(node.typeArguments));
     copy.type = node.type;
     return copy;
   }
 
   @override
-  TypeParameter visitTypeParameter(TypeParameter node) => new TypeParameter(
-      _cloneNode(node.documentationComment),
-      _cloneNodeList(node.metadata),
-      _cloneNode(node.name),
-      _mapToken(node.extendsKeyword),
-      _cloneNode(node.bound));
+  TypeParameter visitTypeParameter(TypeParameter node) =>
+      astFactory.typeParameter(
+          _cloneNode(node.documentationComment),
+          _cloneNodeList(node.metadata),
+          _cloneNode(node.name),
+          _mapToken(node.extendsKeyword),
+          _cloneNode(node.bound));
 
   @override
   TypeParameterList visitTypeParameterList(TypeParameterList node) =>
-      new TypeParameterList(_mapToken(node.leftBracket),
+      astFactory.typeParameterList(_mapToken(node.leftBracket),
           _cloneNodeList(node.typeParameters), _mapToken(node.rightBracket));
 
   @override
   VariableDeclaration visitVariableDeclaration(VariableDeclaration node) =>
-      new VariableDeclaration(_cloneNode(node.name), _mapToken(node.equals),
-          _cloneNode(node.initializer));
+      astFactory.variableDeclaration(_cloneNode(node.name),
+          _mapToken(node.equals), _cloneNode(node.initializer));
 
   @override
   VariableDeclarationList visitVariableDeclarationList(
           VariableDeclarationList node) =>
-      new VariableDeclarationList(
+      astFactory.variableDeclarationList(
           null,
           _cloneNodeList(node.metadata),
           _mapToken(node.keyword),
@@ -3745,27 +3771,29 @@
   @override
   VariableDeclarationStatement visitVariableDeclarationStatement(
           VariableDeclarationStatement node) =>
-      new VariableDeclarationStatement(
+      astFactory.variableDeclarationStatement(
           _cloneNode(node.variables), _mapToken(node.semicolon));
 
   @override
-  WhileStatement visitWhileStatement(WhileStatement node) => new WhileStatement(
-      _mapToken(node.whileKeyword),
-      _mapToken(node.leftParenthesis),
-      _cloneNode(node.condition),
-      _mapToken(node.rightParenthesis),
-      _cloneNode(node.body));
+  WhileStatement visitWhileStatement(WhileStatement node) =>
+      astFactory.whileStatement(
+          _mapToken(node.whileKeyword),
+          _mapToken(node.leftParenthesis),
+          _cloneNode(node.condition),
+          _mapToken(node.rightParenthesis),
+          _cloneNode(node.body));
 
   @override
-  WithClause visitWithClause(WithClause node) => new WithClause(
+  WithClause visitWithClause(WithClause node) => astFactory.withClause(
       _mapToken(node.withKeyword), _cloneNodeList(node.mixinTypes));
 
   @override
-  YieldStatement visitYieldStatement(YieldStatement node) => new YieldStatement(
-      _mapToken(node.yieldKeyword),
-      _mapToken(node.star),
-      _cloneNode(node.expression),
-      _mapToken(node.semicolon));
+  YieldStatement visitYieldStatement(YieldStatement node) =>
+      astFactory.yieldStatement(
+          _mapToken(node.yieldKeyword),
+          _mapToken(node.star),
+          _cloneNode(node.expression),
+          _mapToken(node.semicolon));
 
   AstNode/*=E*/ _cloneNode/*<E extends AstNode>*/(AstNode/*=E*/ node) {
     if (node == null) {
diff --git a/pkg/analyzer/lib/src/dart/constant/evaluation.dart b/pkg/analyzer/lib/src/dart/constant/evaluation.dart
index c335351..8659dfe 100644
--- a/pkg/analyzer/lib/src/dart/constant/evaluation.dart
+++ b/pkg/analyzer/lib/src/dart/constant/evaluation.dart
@@ -29,6 +29,7 @@
 import 'package:analyzer/src/generated/utilities_collection.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart' show ParameterKind;
 import 'package:analyzer/src/task/dart.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 
 /**
  * Helper class encapsulating the methods for evaluating constants and
@@ -717,7 +718,7 @@
           superclass.lookUpConstructor(superName, constructor.library);
       if (superConstructor != null) {
         if (superArguments == null) {
-          superArguments = new NodeList<Expression>(null);
+          superArguments = astFactory.nodeList/*<Expression>*/(null);
         }
 
         evaluateSuperConstructorCall(node, fieldMap, superConstructor,
diff --git a/pkg/analyzer/lib/src/dart/element/element.dart b/pkg/analyzer/lib/src/dart/element/element.dart
index 22f961b..cde2f0f 100644
--- a/pkg/analyzer/lib/src/dart/element/element.dart
+++ b/pkg/analyzer/lib/src/dart/element/element.dart
@@ -116,7 +116,8 @@
   ElementKind get kind => ElementKind.CLASS;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitClassElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitClassElement(this);
 
   @override
   NamedCompilationUnitMember computeNode() {
@@ -1621,7 +1622,8 @@
       object is CompilationUnitElementImpl && source == object.source;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitCompilationUnitElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitCompilationUnitElement(this);
 
   /**
    * This method is invoked after this unit was incrementally resolved.
@@ -2171,7 +2173,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitConstructorElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitConstructorElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -2434,7 +2437,7 @@
   ElementKind get kind => ElementKind.DYNAMIC;
 
   @override
-  accept(ElementVisitor visitor) => null;
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) => null;
 }
 
 /**
@@ -4157,7 +4160,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitExportElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitExportElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -4242,7 +4246,8 @@
   ElementKind get kind => ElementKind.FIELD;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitFieldElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitFieldElement(this);
 
   @override
   AstNode computeNode() {
@@ -4319,7 +4324,7 @@
   }
 
   @override
-  accept(ElementVisitor visitor) =>
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
       visitor.visitFieldFormalParameterElement(this);
 }
 
@@ -4421,7 +4426,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitFunctionElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitFunctionElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -4764,7 +4770,8 @@
       _unlinkedTypedef.typeParameters;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitFunctionTypeAliasElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitFunctionTypeAliasElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -4782,12 +4789,13 @@
       buffer.write(">");
     }
     buffer.write("(");
-    int parameterCount = _parameters.length;
+    List<ParameterElement> parameterList = parameters;
+    int parameterCount = parameterList.length;
     for (int i = 0; i < parameterCount; i++) {
       if (i > 0) {
         buffer.write(", ");
       }
-      (_parameters[i] as ParameterElementImpl).appendTo(buffer);
+      (parameterList[i] as ParameterElementImpl).appendTo(buffer);
     }
     buffer.write(")");
     if (type != null) {
@@ -5109,7 +5117,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitImportElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitImportElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -5238,7 +5247,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitLabelElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitLabelElement(this);
 
   /**
    * Create and return [LabelElement]s for the given [unlinkedLabels].
@@ -5788,7 +5798,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitLibraryElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitLibraryElement(this);
 
   /**
    * Create the [FunctionElement] to be returned by [loadLibraryFunction],
@@ -6078,7 +6089,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitLocalVariableElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitLocalVariableElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -6198,7 +6210,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitMethodElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitMethodElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -6489,7 +6502,8 @@
   CompilationUnit get unit => null;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitMultiplyDefinedElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitMultiplyDefinedElement(this);
 
   @override
   String computeDocumentationComment() => null;
@@ -7181,7 +7195,8 @@
   UnlinkedExpr get _unlinkedConst => _unlinkedParam?.initializer?.bodyExpr;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitParameterElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitParameterElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -7421,7 +7436,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitPrefixElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitPrefixElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -7593,7 +7609,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitPropertyAccessorElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitPropertyAccessorElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
@@ -7933,7 +7950,8 @@
   ElementKind get kind => ElementKind.TOP_LEVEL_VARIABLE;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitTopLevelVariableElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitTopLevelVariableElement(this);
 
   @override
   VariableDeclaration computeNode() =>
@@ -8081,7 +8099,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitTypeParameterElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitTypeParameterElement(this);
 
   @override
   void appendTo(StringBuffer buffer) {
diff --git a/pkg/analyzer/lib/src/dart/element/handle.dart b/pkg/analyzer/lib/src/dart/element/handle.dart
index 93edeca..a157455 100644
--- a/pkg/analyzer/lib/src/dart/element/handle.dart
+++ b/pkg/analyzer/lib/src/dart/element/handle.dart
@@ -409,7 +409,8 @@
       object is Element && object.location == _location;
 
   @override
-  accept(ElementVisitor visitor) => actualElement.accept(visitor);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/> visitor) =>
+      actualElement.accept(visitor);
 
   @override
   String computeDocumentationComment() => documentationComment;
diff --git a/pkg/analyzer/lib/src/dart/element/member.dart b/pkg/analyzer/lib/src/dart/element/member.dart
index 6210e77..d27b814 100644
--- a/pkg/analyzer/lib/src/dart/element/member.dart
+++ b/pkg/analyzer/lib/src/dart/element/member.dart
@@ -60,7 +60,8 @@
       from(baseElement.redirectedConstructor, definingType);
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitConstructorElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitConstructorElement(this);
 
   @override
   ConstructorDeclaration computeNode() => baseElement.computeNode();
@@ -243,7 +244,7 @@
   }
 
   @override
-  accept(ElementVisitor visitor) =>
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
       visitor.visitFieldFormalParameterElement(this);
 }
 
@@ -283,7 +284,8 @@
       PropertyAccessorMember.from(baseElement.setter, definingType);
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitFieldElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitFieldElement(this);
 
   @override
   VariableDeclaration computeNode() => baseElement.computeNode();
@@ -374,7 +376,8 @@
   SourceRange get visibleRange => baseElement.visibleRange;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitFunctionElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitFunctionElement(this);
 
   @override
   FunctionDeclaration computeNode() => baseElement.computeNode();
@@ -593,7 +596,8 @@
   ClassElement get enclosingElement => baseElement.enclosingElement;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitMethodElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitMethodElement(this);
 
   @override
   MethodDeclaration computeNode() => baseElement.computeNode();
@@ -696,7 +700,8 @@
   SourceRange get visibleRange => baseElement.visibleRange;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitParameterElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitParameterElement(this);
 
   @override
   FormalParameter computeNode() => baseElement.computeNode();
@@ -792,7 +797,8 @@
   }
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitPropertyAccessorElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitPropertyAccessorElement(this);
 
   @override
   String toString() {
@@ -923,7 +929,8 @@
   TypeParameterType get type => _type;
 
   @override
-  accept(ElementVisitor visitor) => visitor.visitTypeParameterElement(this);
+  /*=T*/ accept/*<T>*/(ElementVisitor<dynamic/*=T*/ > visitor) =>
+      visitor.visitTypeParameterElement(this);
 
   /**
    * If the given [parameter]'s type is different when any type parameters from
diff --git a/pkg/analyzer/lib/src/dart/element/type.dart b/pkg/analyzer/lib/src/dart/element/type.dart
index bf898e0..32a12a5 100644
--- a/pkg/analyzer/lib/src/dart/element/type.dart
+++ b/pkg/analyzer/lib/src/dart/element/type.dart
@@ -1026,16 +1026,12 @@
     // This type cast is safe, because we checked it above.
     FunctionType s = other as FunctionType;
     if (t.typeFormals.isNotEmpty) {
-      if (s.typeFormals.isEmpty) {
-        t = instantiateToBounds(t);
-      } else {
-        List<DartType> freshVariables = relateTypeFormals(t, s, returnRelation);
-        if (freshVariables == null) {
-          return false;
-        }
-        t = t.instantiate(freshVariables);
-        s = s.instantiate(freshVariables);
+      List<DartType> freshVariables = relateTypeFormals(t, s, returnRelation);
+      if (freshVariables == null) {
+        return false;
       }
+      t = t.instantiate(freshVariables);
+      s = s.instantiate(freshVariables);
     } else if (s.typeFormals.isNotEmpty) {
       return false;
     }
diff --git a/pkg/analyzer/lib/src/dart/resolver/inheritance_manager.dart b/pkg/analyzer/lib/src/dart/resolver/inheritance_manager.dart
index 69d3948..f00cc35 100644
--- a/pkg/analyzer/lib/src/dart/resolver/inheritance_manager.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/inheritance_manager.dart
@@ -5,6 +5,7 @@
 import 'dart:collection';
 
 import 'package:analyzer/dart/ast/ast.dart';
+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/type.dart';
@@ -962,8 +963,8 @@
       int numOfPositionalParameters,
       List<String> namedParameters) {
     DynamicTypeImpl dynamicType = DynamicTypeImpl.instance;
-    SimpleIdentifier nameIdentifier =
-        new SimpleIdentifier(new StringToken(TokenType.IDENTIFIER, name, 0));
+    SimpleIdentifier nameIdentifier = astFactory
+        .simpleIdentifier(new StringToken(TokenType.IDENTIFIER, name, 0));
     ExecutableElementImpl executable;
     ExecutableElement elementToMerge = elementArrayToMerge[0];
     if (elementToMerge is MethodElement) {
diff --git a/pkg/analyzer/lib/src/generated/error_verifier.dart b/pkg/analyzer/lib/src/generated/error_verifier.dart
index 30a50cc..0d6ecf8 100644
--- a/pkg/analyzer/lib/src/generated/error_verifier.dart
+++ b/pkg/analyzer/lib/src/generated/error_verifier.dart
@@ -4989,104 +4989,19 @@
     } else if (_enclosingClass.hasNoSuchMethod) {
       return;
     }
-    //
-    // Store in local sets the set of all method and accessor names
-    //
-    HashSet<ExecutableElement> missingOverrides =
-        new HashSet<ExecutableElement>();
-    //
-    // Loop through the set of all executable elements declared in the implicit
-    // interface.
-    //
-    Map<String, ExecutableElement> membersInheritedFromInterfaces =
-        _inheritanceManager.getMembersInheritedFromInterfaces(_enclosingClass);
-    Map<String, ExecutableElement> membersInheritedFromSuperclasses =
-        _inheritanceManager.getMembersInheritedFromClasses(_enclosingClass);
-    for (String memberName in membersInheritedFromInterfaces.keys) {
-      ExecutableElement executableElt =
-          membersInheritedFromInterfaces[memberName];
-      if (memberName == null) {
-        break;
-      }
-      // If the element is not synthetic and can be determined to be defined in
-      // Object, skip it.
-      if (executableElt.enclosingElement != null &&
-          (executableElt.enclosingElement as ClassElement).type.isObject) {
-        continue;
-      }
-      // Check to see if some element is in local enclosing class that matches
-      // the name of the required member.
-      if (_isMemberInClassOrMixin(executableElt, _enclosingClass)) {
-        // We do not have to verify that this implementation of the found method
-        // matches the required function type: the set of
-        // StaticWarningCode.INVALID_METHOD_OVERRIDE_* warnings break out the
-        // different specific situations.
-        continue;
-      }
-      // First check to see if this element was declared in the superclass
-      // chain, in which case there is already a concrete implementation.
-      ExecutableElement elt = membersInheritedFromSuperclasses[memberName];
-      // Check to see if an element was found in the superclass chain with the
-      // correct name.
-      if (elt != null) {
-        // Reference the types, if any are null then continue.
-        InterfaceType enclosingType = _enclosingClass.type;
-        FunctionType concreteType = elt.type;
-        FunctionType requiredMemberType = executableElt.type;
-        if (enclosingType == null ||
-            concreteType == null ||
-            requiredMemberType == null) {
-          continue;
-        }
-        // Some element was found in the superclass chain that matches the name
-        // of the required member.
-        // If it is not abstract and it is the correct one (types match- the
-        // version of this method that we have has the correct number of
-        // parameters, etc), then this class has a valid implementation of this
-        // method, so skip it.
-        if ((elt is MethodElement && !elt.isAbstract) ||
-            (elt is PropertyAccessorElement && !elt.isAbstract)) {
-          // Since we are comparing two function types, we need to do the
-          // appropriate type substitutions first ().
-          FunctionType foundConcreteFT = _inheritanceManager
-              .substituteTypeArgumentsInMemberFromInheritance(
-                  concreteType, memberName, enclosingType);
-          FunctionType requiredMemberFT = _inheritanceManager
-              .substituteTypeArgumentsInMemberFromInheritance(
-                  requiredMemberType, memberName, enclosingType);
-          foundConcreteFT = _typeSystem.functionTypeToConcreteType(
-              _typeProvider, foundConcreteFT);
-          requiredMemberFT = _typeSystem.functionTypeToConcreteType(
-              _typeProvider, requiredMemberFT);
 
-          // Strong mode does override checking for types in CodeChecker, so
-          // we can skip it here. Doing it here leads to unnecessary duplicate
-          // error messages in subclasses that inherit from one that has an
-          // override error.
-          //
-          // See: https://github.com/dart-lang/sdk/issues/25232
-          if (_options.strongMode ||
-              _typeSystem.isSubtypeOf(foundConcreteFT, requiredMemberFT)) {
-            continue;
-          }
-        }
-      }
-      // The not qualifying concrete executable element was found, add it to the
-      // list.
-      missingOverrides.add(executableElt);
-    }
-    // Now that we have the set of missing overrides, generate a warning on this
-    // class.
-    int missingOverridesSize = missingOverrides.length;
-    if (missingOverridesSize == 0) {
+    Set<ExecutableElement> missingOverrides = computeMissingOverrides(
+        _options.strongMode,
+        _typeProvider,
+        _typeSystem,
+        _inheritanceManager,
+        _enclosingClass);
+    if (missingOverrides.isEmpty) {
       return;
     }
-    List<ExecutableElement> missingOverridesArray =
-        new List.from(missingOverrides);
-    List<String> stringMembersArrayListSet = new List<String>();
-    for (int i = 0; i < missingOverridesArray.length; i++) {
-      String newStrMember;
-      ExecutableElement element = missingOverridesArray[i];
+
+    List<String> missingOverrideNames = <String>[];
+    for (ExecutableElement element in missingOverrides) {
       Element enclosingElement = element.enclosingElement;
       String prefix = StringUtilities.EMPTY;
       if (element is PropertyAccessorElement) {
@@ -5098,60 +5013,57 @@
           // "setter "
         }
       }
+      String newStrMember;
       if (enclosingElement != null) {
         newStrMember =
             "$prefix'${enclosingElement.displayName}.${element.displayName}'";
       } else {
         newStrMember = "$prefix'${element.displayName}'";
       }
-      stringMembersArrayListSet.add(newStrMember);
+      missingOverrideNames.add(newStrMember);
     }
-    List<String> stringMembersArray = new List.from(stringMembersArrayListSet);
-    stringMembersArray.sort();
-    AnalysisErrorWithProperties analysisError;
-    if (stringMembersArray.length == 1) {
-      analysisError = _errorReporter.newErrorWithProperties(
+    missingOverrideNames.sort();
+
+    if (missingOverrideNames.length == 1) {
+      _errorReporter.reportErrorForNode(
           StaticWarningCode.NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_ONE,
           classNameNode,
-          [stringMembersArray[0]]);
-    } else if (stringMembersArray.length == 2) {
-      analysisError = _errorReporter.newErrorWithProperties(
+          [missingOverrideNames[0]]);
+    } else if (missingOverrideNames.length == 2) {
+      _errorReporter.reportErrorForNode(
           StaticWarningCode.NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_TWO,
           classNameNode,
-          [stringMembersArray[0], stringMembersArray[1]]);
-    } else if (stringMembersArray.length == 3) {
-      analysisError = _errorReporter.newErrorWithProperties(
+          [missingOverrideNames[0], missingOverrideNames[1]]);
+    } else if (missingOverrideNames.length == 3) {
+      _errorReporter.reportErrorForNode(
           StaticWarningCode.NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_THREE,
           classNameNode, [
-        stringMembersArray[0],
-        stringMembersArray[1],
-        stringMembersArray[2]
+        missingOverrideNames[0],
+        missingOverrideNames[1],
+        missingOverrideNames[2]
       ]);
-    } else if (stringMembersArray.length == 4) {
-      analysisError = _errorReporter.newErrorWithProperties(
+    } else if (missingOverrideNames.length == 4) {
+      _errorReporter.reportErrorForNode(
           StaticWarningCode.NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FOUR,
           classNameNode, [
-        stringMembersArray[0],
-        stringMembersArray[1],
-        stringMembersArray[2],
-        stringMembersArray[3]
+        missingOverrideNames[0],
+        missingOverrideNames[1],
+        missingOverrideNames[2],
+        missingOverrideNames[3]
       ]);
     } else {
-      analysisError = _errorReporter.newErrorWithProperties(
+      _errorReporter.reportErrorForNode(
           StaticWarningCode
               .NON_ABSTRACT_CLASS_INHERITS_ABSTRACT_MEMBER_FIVE_PLUS,
           classNameNode,
           [
-            stringMembersArray[0],
-            stringMembersArray[1],
-            stringMembersArray[2],
-            stringMembersArray[3],
-            stringMembersArray.length - 4
+            missingOverrideNames[0],
+            missingOverrideNames[1],
+            missingOverrideNames[2],
+            missingOverrideNames[3],
+            missingOverrideNames.length - 4
           ]);
     }
-    analysisError.setProperty(
-        ErrorProperty.UNIMPLEMENTED_METHODS, missingOverridesArray);
-    _errorReporter.reportError(analysisError);
   }
 
   /**
@@ -6537,57 +6449,6 @@
   }
 
   /**
-   * Return `true` iff the given [classElement] has a concrete method, getter or
-   * setter that matches the name of the given [executableElement] in either the
-   * class itself, or one of its' mixins.
-   *
-   * By "match", only the name of the member is tested to match, it does not
-   * have to equal or be a subtype of the given executable element, this is due
-   * to the specific use where this method is used in
-   * [_checkForNonAbstractClassInheritsAbstractMember].
-   */
-  bool _isMemberInClassOrMixin(
-      ExecutableElement executableElement, ClassElement classElement) {
-    ExecutableElement foundElt = null;
-    String executableName = executableElement.name;
-    if (executableElement is MethodElement) {
-      foundElt = classElement.getMethod(executableName);
-      if (foundElt != null && !foundElt.isAbstract) {
-        return true;
-      }
-      List<InterfaceType> mixins = classElement.mixins;
-      for (int i = 0; i < mixins.length && foundElt == null; i++) {
-        foundElt = mixins[i].getMethod(executableName);
-      }
-      if (foundElt != null && !foundElt.isAbstract) {
-        return true;
-      }
-    } else if (executableElement is PropertyAccessorElement) {
-      if (executableElement.isGetter) {
-        foundElt = classElement.getGetter(executableName);
-      }
-      if (foundElt == null && executableElement.isSetter) {
-        foundElt = classElement.getSetter(executableName);
-      }
-      if (foundElt != null &&
-          !(foundElt as PropertyAccessorElement).isAbstract) {
-        return true;
-      }
-      List<InterfaceType> mixins = classElement.mixins;
-      for (int i = 0; i < mixins.length && foundElt == null; i++) {
-        foundElt = mixins[i].getGetter(executableName);
-        if (foundElt == null) {
-          foundElt = mixins[i].getSetter(executableName);
-        }
-      }
-      if (foundElt != null && !foundElt.isAbstract) {
-        return true;
-      }
-    }
-    return false;
-  }
-
-  /**
    * Return `true` if the given 'this' [expression] is in a valid context.
    */
   bool _isThisInValidContext(ThisExpression expression) {
@@ -6712,6 +6573,106 @@
   }
 
   /**
+   * Returns [ExecutableElement]s that are declared in interfaces implemented
+   * by the [classElement], but not implemented by the [classElement] or its
+   * superclasses.
+   */
+  static Set<ExecutableElement> computeMissingOverrides(
+      bool strongMode,
+      TypeProvider typeProvider,
+      TypeSystem typeSystem,
+      InheritanceManager inheritanceManager,
+      ClassElement classElement) {
+    //
+    // Store in local sets the set of all method and accessor names
+    //
+    HashSet<ExecutableElement> missingOverrides =
+        new HashSet<ExecutableElement>();
+    //
+    // Loop through the set of all executable elements declared in the implicit
+    // interface.
+    //
+    Map<String, ExecutableElement> membersInheritedFromInterfaces =
+        inheritanceManager.getMembersInheritedFromInterfaces(classElement);
+    Map<String, ExecutableElement> membersInheritedFromSuperclasses =
+        inheritanceManager.getMembersInheritedFromClasses(classElement);
+    for (String memberName in membersInheritedFromInterfaces.keys) {
+      ExecutableElement executableElt =
+          membersInheritedFromInterfaces[memberName];
+      if (memberName == null) {
+        break;
+      }
+      // If the element is not synthetic and can be determined to be defined in
+      // Object, skip it.
+      if (executableElt.enclosingElement != null &&
+          (executableElt.enclosingElement as ClassElement).type.isObject) {
+        continue;
+      }
+      // Check to see if some element is in local enclosing class that matches
+      // the name of the required member.
+      if (_isMemberInClassOrMixin(executableElt, classElement)) {
+        // We do not have to verify that this implementation of the found method
+        // matches the required function type: the set of
+        // StaticWarningCode.INVALID_METHOD_OVERRIDE_* warnings break out the
+        // different specific situations.
+        continue;
+      }
+      // First check to see if this element was declared in the superclass
+      // chain, in which case there is already a concrete implementation.
+      ExecutableElement elt = membersInheritedFromSuperclasses[memberName];
+      // Check to see if an element was found in the superclass chain with the
+      // correct name.
+      if (elt != null) {
+        // Reference the types, if any are null then continue.
+        InterfaceType enclosingType = classElement.type;
+        FunctionType concreteType = elt.type;
+        FunctionType requiredMemberType = executableElt.type;
+        if (enclosingType == null ||
+            concreteType == null ||
+            requiredMemberType == null) {
+          continue;
+        }
+        // Some element was found in the superclass chain that matches the name
+        // of the required member.
+        // If it is not abstract and it is the correct one (types match- the
+        // version of this method that we have has the correct number of
+        // parameters, etc), then this class has a valid implementation of this
+        // method, so skip it.
+        if ((elt is MethodElement && !elt.isAbstract) ||
+            (elt is PropertyAccessorElement && !elt.isAbstract)) {
+          // Since we are comparing two function types, we need to do the
+          // appropriate type substitutions first ().
+          FunctionType foundConcreteFT =
+              inheritanceManager.substituteTypeArgumentsInMemberFromInheritance(
+                  concreteType, memberName, enclosingType);
+          FunctionType requiredMemberFT =
+              inheritanceManager.substituteTypeArgumentsInMemberFromInheritance(
+                  requiredMemberType, memberName, enclosingType);
+          foundConcreteFT = typeSystem.functionTypeToConcreteType(
+              typeProvider, foundConcreteFT);
+          requiredMemberFT = typeSystem.functionTypeToConcreteType(
+              typeProvider, requiredMemberFT);
+
+          // Strong mode does override checking for types in CodeChecker, so
+          // we can skip it here. Doing it here leads to unnecessary duplicate
+          // error messages in subclasses that inherit from one that has an
+          // override error.
+          //
+          // See: https://github.com/dart-lang/sdk/issues/25232
+          if (strongMode ||
+              typeSystem.isSubtypeOf(foundConcreteFT, requiredMemberFT)) {
+            continue;
+          }
+        }
+      }
+      // The not qualifying concrete executable element was found, add it to the
+      // list.
+      missingOverrides.add(executableElt);
+    }
+    return missingOverrides;
+  }
+
+  /**
    * Return the static type of the given [expression] that is to be used for
    * type analysis.
    */
@@ -6737,6 +6698,57 @@
     }
     return null;
   }
+
+  /**
+   * Return `true` iff the given [classElement] has a concrete method, getter or
+   * setter that matches the name of the given [executableElement] in either the
+   * class itself, or one of its' mixins.
+   *
+   * By "match", only the name of the member is tested to match, it does not
+   * have to equal or be a subtype of the given executable element, this is due
+   * to the specific use where this method is used in
+   * [_checkForNonAbstractClassInheritsAbstractMember].
+   */
+  static bool _isMemberInClassOrMixin(
+      ExecutableElement executableElement, ClassElement classElement) {
+    ExecutableElement foundElt = null;
+    String executableName = executableElement.name;
+    if (executableElement is MethodElement) {
+      foundElt = classElement.getMethod(executableName);
+      if (foundElt != null && !foundElt.isAbstract) {
+        return true;
+      }
+      List<InterfaceType> mixins = classElement.mixins;
+      for (int i = 0; i < mixins.length && foundElt == null; i++) {
+        foundElt = mixins[i].getMethod(executableName);
+      }
+      if (foundElt != null && !foundElt.isAbstract) {
+        return true;
+      }
+    } else if (executableElement is PropertyAccessorElement) {
+      if (executableElement.isGetter) {
+        foundElt = classElement.getGetter(executableName);
+      }
+      if (foundElt == null && executableElement.isSetter) {
+        foundElt = classElement.getSetter(executableName);
+      }
+      if (foundElt != null &&
+          !(foundElt as PropertyAccessorElement).isAbstract) {
+        return true;
+      }
+      List<InterfaceType> mixins = classElement.mixins;
+      for (int i = 0; i < mixins.length && foundElt == null; i++) {
+        foundElt = mixins[i].getGetter(executableName);
+        if (foundElt == null) {
+          foundElt = mixins[i].getSetter(executableName);
+        }
+      }
+      if (foundElt != null && !foundElt.isAbstract) {
+        return true;
+      }
+    }
+    return false;
+  }
 }
 
 class GeneralizingElementVisitor_ErrorVerifier_hasTypedefSelfReference
diff --git a/pkg/analyzer/lib/src/generated/parser.dart b/pkg/analyzer/lib/src/generated/parser.dart
index 58b4ba0..c16281e 100644
--- a/pkg/analyzer/lib/src/generated/parser.dart
+++ b/pkg/analyzer/lib/src/generated/parser.dart
@@ -8,6 +8,7 @@
 import "dart:math" as math;
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/error/listener.dart';
@@ -393,14 +394,15 @@
     } else {
       syntheticToken = _createSyntheticToken(TokenType.IDENTIFIER);
     }
-    return new SimpleIdentifier(syntheticToken, isDeclaration: isDeclaration);
+    return astFactory.simpleIdentifier(syntheticToken,
+        isDeclaration: isDeclaration);
   }
 
   /**
    * Return a synthetic string literal.
    */
-  SimpleStringLiteral createSyntheticStringLiteral() =>
-      new SimpleStringLiteral(_createSyntheticToken(TokenType.STRING), "");
+  SimpleStringLiteral createSyntheticStringLiteral() => astFactory
+      .simpleStringLiteral(_createSyntheticToken(TokenType.STRING), "");
 
   /**
    * Advance to the next token in the token stream, making it the new current
@@ -599,12 +601,12 @@
     Expression expression;
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type.isAdditiveOperator) {
-      expression = new SuperExpression(getAndAdvance());
+      expression = astFactory.superExpression(getAndAdvance());
     } else {
       expression = parseMultiplicativeExpression();
     }
     while (_currentToken.type.isAdditiveOperator) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseMultiplicativeExpression());
     }
     return expression;
@@ -631,7 +633,8 @@
     if (_matches(TokenType.OPEN_PAREN)) {
       arguments = parseArgumentList();
     }
-    return new Annotation(atSign, name, period, constructorName, arguments);
+    return astFactory.annotation(
+        atSign, name, period, constructorName, arguments);
   }
 
   /**
@@ -653,7 +656,7 @@
     // namedArgument can have an identifier followed by a colon.
     //
     if (_matchesIdentifier() && _tokenMatches(_peek(), TokenType.COLON)) {
-      return new NamedExpression(parseLabel(), parseExpression2());
+      return astFactory.namedExpression(parseLabel(), parseExpression2());
     } else {
       return parseExpression2();
     }
@@ -674,7 +677,7 @@
   ArgumentList parseArgumentList() {
     Token leftParenthesis = getAndAdvance();
     if (_matches(TokenType.CLOSE_PAREN)) {
-      return new ArgumentList(leftParenthesis, null, getAndAdvance());
+      return astFactory.argumentList(leftParenthesis, null, getAndAdvance());
     }
     //
     // Even though unnamed arguments must all appear before any named arguments,
@@ -712,7 +715,8 @@
       // If there is, then we're more likely missing a comma and should go back
       // to parsing arguments.
       Token rightParenthesis = _expect(TokenType.CLOSE_PAREN);
-      return new ArgumentList(leftParenthesis, arguments, rightParenthesis);
+      return astFactory.argumentList(
+          leftParenthesis, arguments, rightParenthesis);
     } finally {
       _inInitializer = wasInInitializer;
     }
@@ -738,7 +742,7 @@
     }
     Token rightParen = _expect(TokenType.CLOSE_PAREN);
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new AssertStatement(
+    return astFactory.assertStatement(
         keyword, leftParen, expression, comma, message, rightParen, semicolon);
   }
 
@@ -755,7 +759,7 @@
   Expression parseAssignableExpression(bool primaryAllowed) {
     if (_matchesKeyword(Keyword.SUPER)) {
       return parseAssignableSelector(
-          new SuperExpression(getAndAdvance()), false,
+          astFactory.superExpression(getAndAdvance()), false,
           allowConditional: false);
     }
     return _parseAssignableExpressionNotStartingWithSuper(primaryAllowed);
@@ -786,7 +790,7 @@
       try {
         Expression index = parseExpression2();
         Token rightBracket = _expect(TokenType.CLOSE_SQUARE_BRACKET);
-        return new IndexExpression.forTarget(
+        return astFactory.indexExpressionForTarget(
             prefix, leftBracket, index, rightBracket);
       } finally {
         _inInitializer = wasInInitializer;
@@ -800,13 +804,14 @@
               [_currentToken.lexeme]);
         }
         Token operator = getAndAdvance();
-        return new PropertyAccess(prefix, operator, parseSimpleIdentifier());
+        return astFactory.propertyAccess(
+            prefix, operator, parseSimpleIdentifier());
       } else if (type == TokenType.INDEX) {
         _splitIndex();
         Token leftBracket = getAndAdvance();
         Expression index = parseSimpleIdentifier();
         Token rightBracket = getAndAdvance();
-        return new IndexExpression.forTarget(
+        return astFactory.indexExpressionForTarget(
             prefix, leftBracket, index, rightBracket);
       } else {
         if (!optional) {
@@ -830,7 +835,7 @@
   AwaitExpression parseAwaitExpression() {
     Token awaitToken = getAndAdvance();
     Expression expression = parseUnaryExpression();
-    return new AwaitExpression(awaitToken, expression);
+    return astFactory.awaitExpression(awaitToken, expression);
   }
 
   /**
@@ -845,12 +850,12 @@
     Expression expression;
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type == TokenType.AMPERSAND) {
-      expression = new SuperExpression(getAndAdvance());
+      expression = astFactory.superExpression(getAndAdvance());
     } else {
       expression = parseShiftExpression();
     }
     while (_currentToken.type == TokenType.AMPERSAND) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseShiftExpression());
     }
     return expression;
@@ -868,12 +873,12 @@
     Expression expression;
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type == TokenType.BAR) {
-      expression = new SuperExpression(getAndAdvance());
+      expression = astFactory.superExpression(getAndAdvance());
     } else {
       expression = parseBitwiseXorExpression();
     }
     while (_currentToken.type == TokenType.BAR) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseBitwiseXorExpression());
     }
     return expression;
@@ -891,12 +896,12 @@
     Expression expression;
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type == TokenType.CARET) {
-      expression = new SuperExpression(getAndAdvance());
+      expression = astFactory.superExpression(getAndAdvance());
     } else {
       expression = parseBitwiseAndExpression();
     }
     while (_currentToken.type == TokenType.CARET) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseBitwiseAndExpression());
     }
     return expression;
@@ -937,7 +942,7 @@
     // there is, then we're more likely missing a semi-colon and should go back
     // to parsing statements.
     Token rightBracket = _expect(TokenType.CLOSE_CURLY_BRACKET);
-    return new Block(leftBracket, statements, rightBracket);
+    return astFactory.block(leftBracket, statements, rightBracket);
   }
 
   /**
@@ -958,7 +963,7 @@
       _reportErrorForToken(ParserErrorCode.BREAK_OUTSIDE_OF_LOOP, breakKeyword);
     }
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new BreakStatement(breakKeyword, label, semicolon);
+    return astFactory.breakStatement(breakKeyword, label, semicolon);
   }
 
   /**
@@ -992,7 +997,7 @@
       try {
         Expression index = parseExpression2();
         Token rightBracket = _expect(TokenType.CLOSE_SQUARE_BRACKET);
-        expression = new IndexExpression.forCascade(
+        expression = astFactory.indexExpressionForCascade(
             period, leftBracket, index, rightBracket);
         period = null;
       } finally {
@@ -1009,21 +1014,21 @@
       do {
         TypeArgumentList typeArguments = _parseOptionalTypeArguments();
         if (functionName != null) {
-          expression = new MethodInvocation(expression, period, functionName,
-              typeArguments, parseArgumentList());
+          expression = astFactory.methodInvocation(expression, period,
+              functionName, typeArguments, parseArgumentList());
           period = null;
           functionName = null;
         } else if (expression == null) {
           // It should not be possible to get here.
-          expression = new MethodInvocation(expression, period,
+          expression = astFactory.methodInvocation(expression, period,
               createSyntheticIdentifier(), typeArguments, parseArgumentList());
         } else {
-          expression = new FunctionExpressionInvocation(
+          expression = astFactory.functionExpressionInvocation(
               expression, typeArguments, parseArgumentList());
         }
       } while (_isLikelyArgumentList());
     } else if (functionName != null) {
-      expression = new PropertyAccess(expression, period, functionName);
+      expression = astFactory.propertyAccess(expression, period, functionName);
       period = null;
     }
     assert(expression != null);
@@ -1038,14 +1043,14 @@
           TypeArgumentList typeArguments = _parseOptionalTypeArguments();
           Expression currentExpression = expression;
           if (currentExpression is PropertyAccess) {
-            expression = new MethodInvocation(
+            expression = astFactory.methodInvocation(
                 currentExpression.target,
                 currentExpression.operator,
                 currentExpression.propertyName,
                 typeArguments,
                 parseArgumentList());
           } else {
-            expression = new FunctionExpressionInvocation(
+            expression = astFactory.functionExpressionInvocation(
                 expression, typeArguments, parseArgumentList());
           }
         }
@@ -1054,7 +1059,7 @@
     if (_currentToken.type.isAssignmentOperator) {
       Token operator = getAndAdvance();
       _ensureAssignable(expression);
-      expression = new AssignmentExpression(
+      expression = astFactory.assignmentExpression(
           expression, operator, parseExpressionWithoutCascade());
     }
     return expression;
@@ -1176,7 +1181,7 @@
       rightBracket = _createSyntheticToken(TokenType.CLOSE_CURLY_BRACKET);
       _reportErrorForCurrentToken(ParserErrorCode.MISSING_CLASS_BODY);
     }
-    ClassDeclaration classDeclaration = new ClassDeclaration(
+    ClassDeclaration classDeclaration = astFactory.classDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         abstractKeyword,
@@ -1207,8 +1212,8 @@
     Modifiers modifiers = parseModifiers();
     Keyword keyword = _currentToken.keyword;
     if (keyword == Keyword.VOID) {
-      TypeName returnType =
-          new TypeName(new SimpleIdentifier(getAndAdvance()), null);
+      TypeName returnType = astFactory.typeName(
+          astFactory.simpleIdentifier(getAndAdvance()), null);
       keyword = _currentToken.keyword;
       Token next = _peek();
       bool isFollowedByIdentifier = _tokenMatchesIdentifier(next);
@@ -1327,14 +1332,15 @@
         // We appear to have found an incomplete field declaration.
         //
         _reportErrorForCurrentToken(ParserErrorCode.MISSING_IDENTIFIER);
-        VariableDeclaration variable =
-            new VariableDeclaration(createSyntheticIdentifier(), null, null);
+        VariableDeclaration variable = astFactory.variableDeclaration(
+            createSyntheticIdentifier(), null, null);
         List<VariableDeclaration> variables = <VariableDeclaration>[variable];
-        return new FieldDeclaration(
+        return astFactory.fieldDeclaration(
             commentAndMetadata.comment,
             commentAndMetadata.metadata,
             null,
-            new VariableDeclarationList(null, null, keyword, null, variables),
+            astFactory.variableDeclarationList(
+                null, null, keyword, null, variables),
             _expect(TokenType.SEMICOLON));
       }
       _reportErrorForToken(
@@ -1347,7 +1353,7 @@
         // to loose, so we'll treat it as a method declaration with a missing
         // name, parameters and empty body.
         //
-        return new MethodDeclaration(
+        return astFactory.methodDeclaration(
             commentAndMetadata.comment,
             commentAndMetadata.metadata,
             null,
@@ -1357,9 +1363,10 @@
             null,
             createSyntheticIdentifier(isDeclaration: true),
             null,
-            new FormalParameterList(
+            astFactory.formalParameterList(
                 null, <FormalParameter>[], null, null, null),
-            new EmptyFunctionBody(_createSyntheticToken(TokenType.SEMICOLON)));
+            astFactory
+                .emptyFunctionBody(_createSyntheticToken(TokenType.SEMICOLON)));
       }
       return null;
     } else if (_tokenMatches(next, TokenType.PERIOD) &&
@@ -1387,7 +1394,7 @@
             modifiers.externalKeyword,
             _validateModifiersForConstructor(modifiers),
             modifiers.factoryKeyword,
-            new SimpleIdentifier(methodName.token, isDeclaration: false),
+            astFactory.simpleIdentifier(methodName.token, isDeclaration: false),
             null,
             null,
             parameters);
@@ -1495,7 +1502,7 @@
             modifiers.externalKeyword,
             _validateModifiersForConstructor(modifiers),
             modifiers.factoryKeyword,
-            new SimpleIdentifier(methodName.token, isDeclaration: true),
+            astFactory.simpleIdentifier(methodName.token, isDeclaration: true),
             null,
             null,
             parameters);
@@ -1563,9 +1570,9 @@
    */
   Combinator parseCombinator() {
     if (_matchesString(_SHOW)) {
-      return new ShowCombinator(getAndAdvance(), parseIdentifierList());
+      return astFactory.showCombinator(getAndAdvance(), parseIdentifierList());
     } else if (_matchesString(_HIDE)) {
-      return new HideCombinator(getAndAdvance(), parseIdentifierList());
+      return astFactory.hideCombinator(getAndAdvance(), parseIdentifierList());
     }
     return null;
   }
@@ -1645,7 +1652,8 @@
         Token syntheticToken =
             new SyntheticStringToken(TokenType.IDENTIFIER, "", sourceOffset);
         syntheticToken.setNext(firstToken);
-        return new CommentReference(null, new SimpleIdentifier(syntheticToken));
+        return astFactory.commentReference(
+            null, astFactory.simpleIdentifier(syntheticToken));
       }
       Token newKeyword = null;
       if (_tokenMatchesKeyword(firstToken, Keyword.NEW)) {
@@ -1656,16 +1664,16 @@
         if (firstToken.next.type != TokenType.EOF) {
           return null;
         }
-        Identifier identifier = new SimpleIdentifier(firstToken);
-        return new CommentReference(null, identifier);
+        Identifier identifier = astFactory.simpleIdentifier(firstToken);
+        return astFactory.commentReference(null, identifier);
       } else if (_tokenMatchesKeyword(firstToken, Keyword.OPERATOR)) {
         Token secondToken = firstToken.next;
         if (secondToken.isUserDefinableOperator) {
           if (secondToken.next.type != TokenType.EOF) {
             return null;
           }
-          Identifier identifier = new SimpleIdentifier(secondToken);
-          return new CommentReference(null, identifier);
+          Identifier identifier = astFactory.simpleIdentifier(secondToken);
+          return astFactory.commentReference(null, identifier);
         }
         return null;
       } else if (_tokenMatchesIdentifier(firstToken)) {
@@ -1675,37 +1683,37 @@
         Identifier identifier;
         if (_tokenMatches(secondToken, TokenType.PERIOD)) {
           if (thirdToken.isUserDefinableOperator) {
-            identifier = new PrefixedIdentifier(
-                new SimpleIdentifier(firstToken),
+            identifier = astFactory.prefixedIdentifier(
+                astFactory.simpleIdentifier(firstToken),
                 secondToken,
-                new SimpleIdentifier(thirdToken));
+                astFactory.simpleIdentifier(thirdToken));
             nextToken = thirdToken.next;
           } else if (_tokenMatchesKeyword(thirdToken, Keyword.OPERATOR)) {
             Token fourthToken = thirdToken.next;
             if (fourthToken.isUserDefinableOperator) {
-              identifier = new PrefixedIdentifier(
-                  new SimpleIdentifier(firstToken),
+              identifier = astFactory.prefixedIdentifier(
+                  astFactory.simpleIdentifier(firstToken),
                   secondToken,
-                  new SimpleIdentifier(fourthToken));
+                  astFactory.simpleIdentifier(fourthToken));
               nextToken = fourthToken.next;
             } else {
               return null;
             }
           } else if (_tokenMatchesIdentifier(thirdToken)) {
-            identifier = new PrefixedIdentifier(
-                new SimpleIdentifier(firstToken),
+            identifier = astFactory.prefixedIdentifier(
+                astFactory.simpleIdentifier(firstToken),
                 secondToken,
-                new SimpleIdentifier(thirdToken));
+                astFactory.simpleIdentifier(thirdToken));
             nextToken = thirdToken.next;
           }
         } else {
-          identifier = new SimpleIdentifier(firstToken);
+          identifier = astFactory.simpleIdentifier(firstToken);
           nextToken = firstToken.next;
         }
         if (nextToken.type != TokenType.EOF) {
           return null;
         }
-        return new CommentReference(newKeyword, identifier);
+        return astFactory.commentReference(newKeyword, identifier);
       } else {
         Keyword keyword = firstToken.keyword;
         if (keyword == Keyword.THIS ||
@@ -1795,8 +1803,8 @@
                   TokenType.IDENTIFIER, '', nameOffset);
             }
             nameToken.setNext(new SimpleToken(TokenType.EOF, nameToken.end));
-            references.add(
-                new CommentReference(null, new SimpleIdentifier(nameToken)));
+            references.add(astFactory.commentReference(
+                null, astFactory.simpleIdentifier(nameToken)));
             token.references.add(nameToken);
             // next character
             rightIndex = leftIndex + 1;
@@ -1840,7 +1848,7 @@
     Token firstToken = _currentToken;
     ScriptTag scriptTag = null;
     if (_matches(TokenType.SCRIPT_TAG)) {
-      scriptTag = new ScriptTag(getAndAdvance());
+      scriptTag = astFactory.scriptTag(getAndAdvance());
     }
     //
     // Even though all directives must appear before declarations and must occur
@@ -1971,7 +1979,7 @@
 //        }
       }
     }
-    return new CompilationUnit(
+    return astFactory.compilationUnit(
         firstToken, scriptTag, directives, declarations, _currentToken);
   }
 
@@ -2012,8 +2020,8 @@
       _validateModifiersForEnum(modifiers);
       return parseEnumDeclaration(commentAndMetadata);
     } else if (keyword == Keyword.VOID) {
-      TypeName returnType =
-          new TypeName(new SimpleIdentifier(getAndAdvance()), null);
+      TypeName returnType = astFactory.typeName(
+          astFactory.simpleIdentifier(getAndAdvance()), null);
       keyword = _currentToken.keyword;
       next = _peek();
       if ((keyword == Keyword.GET || keyword == Keyword.SET) &&
@@ -2052,7 +2060,7 @@
             // We appear to have a variable declaration with a type of "void".
             //
             _reportErrorForNode(ParserErrorCode.VOID_VARIABLE, returnType);
-            return new TopLevelVariableDeclaration(
+            return astFactory.topLevelVariableDeclaration(
                 commentAndMetadata.comment,
                 commentAndMetadata.metadata,
                 parseVariableDeclarationListAfterType(null,
@@ -2089,13 +2097,14 @@
         // We appear to have found an incomplete top-level variable declaration.
         //
         _reportErrorForCurrentToken(ParserErrorCode.MISSING_IDENTIFIER);
-        VariableDeclaration variable =
-            new VariableDeclaration(createSyntheticIdentifier(), null, null);
+        VariableDeclaration variable = astFactory.variableDeclaration(
+            createSyntheticIdentifier(), null, null);
         List<VariableDeclaration> variables = <VariableDeclaration>[variable];
-        return new TopLevelVariableDeclaration(
+        return astFactory.topLevelVariableDeclaration(
             commentAndMetadata.comment,
             commentAndMetadata.metadata,
-            new VariableDeclarationList(null, null, keyword, null, variables),
+            astFactory.variableDeclarationList(
+                null, null, keyword, null, variables),
             _expect(TokenType.SEMICOLON));
       }
       _reportErrorForToken(ParserErrorCode.EXPECTED_EXECUTABLE, _currentToken);
@@ -2119,7 +2128,7 @@
         _reportErrorForCurrentToken(
             ParserErrorCode.MISSING_CONST_FINAL_VAR_OR_TYPE);
       }
-      return new TopLevelVariableDeclaration(
+      return astFactory.topLevelVariableDeclaration(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
           parseVariableDeclarationListAfterType(
@@ -2142,7 +2151,7 @@
           returnType,
           getAndAdvance()));
     } else if (_matches(TokenType.AT)) {
-      return new TopLevelVariableDeclaration(
+      return astFactory.topLevelVariableDeclaration(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
           parseVariableDeclarationListAfterType(null,
@@ -2158,13 +2167,14 @@
       } else {
         semicolon = _createSyntheticToken(TokenType.SEMICOLON);
       }
-      VariableDeclaration variable =
-          new VariableDeclaration(createSyntheticIdentifier(), null, null);
+      VariableDeclaration variable = astFactory.variableDeclaration(
+          createSyntheticIdentifier(), null, null);
       List<VariableDeclaration> variables = <VariableDeclaration>[variable];
-      return new TopLevelVariableDeclaration(
+      return astFactory.topLevelVariableDeclaration(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
-          new VariableDeclarationList(null, null, null, returnType, variables),
+          astFactory.variableDeclarationList(
+              null, null, null, returnType, variables),
           semicolon);
     } else if (next.matchesAny(const <TokenType>[
       TokenType.OPEN_PAREN,
@@ -2176,7 +2186,7 @@
       return parseFunctionDeclaration(
           commentAndMetadata, modifiers.externalKeyword, returnType);
     }
-    return new TopLevelVariableDeclaration(
+    return astFactory.topLevelVariableDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         parseVariableDeclarationListAfterType(
@@ -2200,7 +2210,7 @@
     Expression thenExpression = parseExpressionWithoutCascade();
     Token colon = _expect(TokenType.COLON);
     Expression elseExpression = parseExpressionWithoutCascade();
-    return new ConditionalExpression(
+    return astFactory.conditionalExpression(
         condition, question, thenExpression, colon, elseExpression);
   }
 
@@ -2234,8 +2244,8 @@
     }
     Token rightParenthesis = _expect(TokenType.CLOSE_PAREN);
     StringLiteral libraryUri = _parseUri();
-    return new Configuration(ifKeyword, leftParenthesis, name, equalToken,
-        value, rightParenthesis, libraryUri);
+    return astFactory.configuration(ifKeyword, leftParenthesis, name,
+        equalToken, value, rightParenthesis, libraryUri);
   }
 
   /**
@@ -2292,8 +2302,12 @@
           type != TokenType.FUNCTION) {
         equals = _createSyntheticToken(TokenType.EQ);
       } else {
-        return new ConstructorFieldInitializer(keywordToken, period, fieldName,
-            _createSyntheticToken(TokenType.EQ), createSyntheticIdentifier());
+        return astFactory.constructorFieldInitializer(
+            keywordToken,
+            period,
+            fieldName,
+            _createSyntheticToken(TokenType.EQ),
+            createSyntheticIdentifier());
       }
     }
     bool wasInInitializer = _inInitializer;
@@ -2308,9 +2322,9 @@
             cascadeSections.add(section);
           }
         } while (_matches(TokenType.PERIOD_PERIOD));
-        expression = new CascadeExpression(expression, cascadeSections);
+        expression = astFactory.cascadeExpression(expression, cascadeSections);
       }
-      return new ConstructorFieldInitializer(
+      return astFactory.constructorFieldInitializer(
           keywordToken, period, fieldName, equals, expression);
     } finally {
       _inInitializer = wasInInitializer;
@@ -2332,7 +2346,7 @@
       period = getAndAdvance();
       name = parseSimpleIdentifier();
     }
-    return new ConstructorName(type, period, name);
+    return astFactory.constructorName(type, period, name);
   }
 
   /**
@@ -2358,7 +2372,7 @@
           ParserErrorCode.CONTINUE_WITHOUT_LABEL_IN_CASE, continueKeyword);
     }
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new ContinueStatement(continueKeyword, label, semicolon);
+    return astFactory.continueStatement(continueKeyword, label, semicolon);
   }
 
   /**
@@ -2411,7 +2425,7 @@
     Token firstToken = _currentToken;
     ScriptTag scriptTag = null;
     if (_matches(TokenType.SCRIPT_TAG)) {
-      scriptTag = new ScriptTag(getAndAdvance());
+      scriptTag = astFactory.scriptTag(getAndAdvance());
     }
     List<Directive> directives = <Directive>[];
     while (!_matches(TokenType.EOF)) {
@@ -2432,11 +2446,11 @@
         while (!_matches(TokenType.EOF)) {
           _advance();
         }
-        return new CompilationUnit(
+        return astFactory.compilationUnit(
             firstToken, scriptTag, directives, null, _currentToken);
       }
     }
-    return new CompilationUnit(
+    return astFactory.compilationUnit(
         firstToken, scriptTag, directives, null, _currentToken);
   }
 
@@ -2454,7 +2468,7 @@
       return null;
     }
     List<CommentReference> references = parseCommentReferences(tokens);
-    return Comment.createDocumentationCommentWithReferences(tokens, references);
+    return astFactory.documentationComment(tokens, references);
   }
 
   /**
@@ -2505,8 +2519,8 @@
       Expression condition = parseExpression2();
       Token rightParenthesis = _expect(TokenType.CLOSE_PAREN);
       Token semicolon = _expect(TokenType.SEMICOLON);
-      return new DoStatement(doKeyword, body, whileKeyword, leftParenthesis,
-          condition, rightParenthesis, semicolon);
+      return astFactory.doStatement(doKeyword, body, whileKeyword,
+          leftParenthesis, condition, rightParenthesis, semicolon);
     } finally {
       _inLoop = wasInLoop;
     }
@@ -2525,7 +2539,7 @@
     while (_optional(TokenType.PERIOD)) {
       components.add(parseSimpleIdentifier());
     }
-    return new DottedName(components);
+    return astFactory.dottedName(components);
   }
 
   /**
@@ -2536,7 +2550,7 @@
    *     emptyStatement ::=
    *         ';'
    */
-  Statement parseEmptyStatement() => new EmptyStatement(getAndAdvance());
+  Statement parseEmptyStatement() => astFactory.emptyStatement(getAndAdvance());
 
   /**
    * Parse an enum declaration. The [commentAndMetadata] is the metadata to be
@@ -2577,7 +2591,7 @@
       rightBracket = _createSyntheticToken(TokenType.CLOSE_CURLY_BRACKET);
       _reportErrorForCurrentToken(ParserErrorCode.MISSING_ENUM_BODY);
     }
-    return new EnumDeclaration(
+    return astFactory.enumDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         keyword,
@@ -2599,7 +2613,7 @@
     Expression expression;
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type.isEqualityOperator) {
-      expression = new SuperExpression(getAndAdvance());
+      expression = astFactory.superExpression(getAndAdvance());
     } else {
       expression = parseRelationalExpression();
     }
@@ -2609,7 +2623,7 @@
         _reportErrorForNode(
             ParserErrorCode.EQUALITY_CANNOT_BE_EQUALITY_OPERAND, expression);
       }
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseRelationalExpression());
       leftEqualityExpression = true;
     }
@@ -2631,7 +2645,7 @@
     List<Configuration> configurations = _parseConfigurations();
     List<Combinator> combinators = parseCombinators();
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new ExportDirective(
+    return astFactory.exportDirective(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         exportKeyword,
@@ -2684,11 +2698,12 @@
           cascadeSections.add(section);
         }
       } while (_currentToken.type == TokenType.PERIOD_PERIOD);
-      return new CascadeExpression(expression, cascadeSections);
+      return astFactory.cascadeExpression(expression, cascadeSections);
     } else if (type.isAssignmentOperator) {
       Token operator = getAndAdvance();
       _ensureAssignable(expression);
-      return new AssignmentExpression(expression, operator, parseExpression2());
+      return astFactory.assignmentExpression(
+          expression, operator, parseExpression2());
     }
     return expression;
   }
@@ -2732,7 +2747,7 @@
     if (_currentToken.type.isAssignmentOperator) {
       Token operator = getAndAdvance();
       _ensureAssignable(expression);
-      expression = new AssignmentExpression(
+      expression = astFactory.assignmentExpression(
           expression, operator, parseExpressionWithoutCascade());
     }
     return expression;
@@ -2751,7 +2766,7 @@
     Token keyword = getAndAdvance();
     TypeName superclass = parseTypeName(false);
     _mustNotBeNullable(superclass, ParserErrorCode.NULLABLE_TYPE_IN_EXTENDS);
-    return new ExtendsClause(keyword, superclass);
+    return astFactory.extendsClause(keyword, superclass);
   }
 
   /**
@@ -2822,7 +2837,7 @@
             ParserErrorCode.POSITIONAL_PARAMETER_OUTSIDE_GROUP, parameter);
         kind = ParameterKind.POSITIONAL;
       }
-      return new DefaultFormalParameter(
+      return astFactory.defaultFormalParameter(
           parameter, kind, separator, defaultValue);
     } else if (type == TokenType.COLON) {
       Token separator = getAndAdvance();
@@ -2836,10 +2851,10 @@
             ParserErrorCode.NAMED_PARAMETER_OUTSIDE_GROUP, parameter);
         kind = ParameterKind.NAMED;
       }
-      return new DefaultFormalParameter(
+      return astFactory.defaultFormalParameter(
           parameter, kind, separator, defaultValue);
     } else if (kind != ParameterKind.REQUIRED) {
-      return new DefaultFormalParameter(parameter, kind, null, null);
+      return astFactory.defaultFormalParameter(parameter, kind, null, null);
     }
     return parameter;
   }
@@ -2912,9 +2927,12 @@
             (_tokenMatchesKeyword(_peek(), Keyword.IN) ||
                 _tokenMatches(_peek(), TokenType.COLON))) {
           SimpleIdentifier variableName = _parseSimpleIdentifierUnchecked();
-          variableList = new VariableDeclarationList(commentAndMetadata.comment,
-              commentAndMetadata.metadata, null, null, <VariableDeclaration>[
-            new VariableDeclaration(variableName, null, null)
+          variableList = astFactory.variableDeclarationList(
+              commentAndMetadata.comment,
+              commentAndMetadata.metadata,
+              null,
+              null, <VariableDeclaration>[
+            astFactory.variableDeclaration(variableName, null, null)
           ]);
         } else if (isInitializedVariableDeclaration()) {
           variableList =
@@ -2948,12 +2966,12 @@
             Token keyword = variableList.keyword;
             TypeName type = variableList.type;
             if (keyword != null || type != null) {
-              loopVariable = new DeclaredIdentifier(
+              loopVariable = astFactory.declaredIdentifier(
                   commentAndMetadata.comment,
                   commentAndMetadata.metadata,
                   keyword,
                   type,
-                  new SimpleIdentifier(variable.name.token,
+                  astFactory.simpleIdentifier(variable.name.token,
                       isDeclaration: true));
             } else {
               if (commentAndMetadata.hasMetadata) {
@@ -2969,7 +2987,7 @@
           Token rightParenthesis = _expect(TokenType.CLOSE_PAREN);
           Statement body = parseStatement2();
           if (loopVariable == null) {
-            return new ForEachStatement.withReference(
+            return astFactory.forEachStatementWithReference(
                 awaitKeyword,
                 forKeyword,
                 leftParenthesis,
@@ -2979,7 +2997,7 @@
                 rightParenthesis,
                 body);
           }
-          return new ForEachStatement.withDeclaration(
+          return astFactory.forEachStatementWithDeclaration(
               awaitKeyword,
               forKeyword,
               leftParenthesis,
@@ -3006,7 +3024,7 @@
       }
       Token rightParenthesis = _expect(TokenType.CLOSE_PAREN);
       Statement body = parseStatement2();
-      return new ForStatement(
+      return astFactory.forStatement(
           forKeyword,
           leftParenthesis,
           variableList,
@@ -3053,7 +3071,7 @@
         if (!mayBeEmpty) {
           _reportErrorForCurrentToken(emptyErrorCode);
         }
-        return new EmptyFunctionBody(getAndAdvance());
+        return astFactory.emptyFunctionBody(getAndAdvance());
       }
       Token keyword = null;
       Token star = null;
@@ -3102,10 +3120,10 @@
           semicolon = _expect(TokenType.SEMICOLON);
         }
         if (!_parseFunctionBodies) {
-          return new EmptyFunctionBody(
-              _createSyntheticToken(TokenType.SEMICOLON));
+          return astFactory
+              .emptyFunctionBody(_createSyntheticToken(TokenType.SEMICOLON));
         }
-        return new ExpressionFunctionBody(
+        return astFactory.expressionFunctionBody(
             keyword, functionDefinition, expression, semicolon);
       } else if (type == TokenType.OPEN_CURLY_BRACKET) {
         if (keyword != null) {
@@ -3116,23 +3134,23 @@
         }
         if (!_parseFunctionBodies) {
           _skipBlock();
-          return new EmptyFunctionBody(
-              _createSyntheticToken(TokenType.SEMICOLON));
+          return astFactory
+              .emptyFunctionBody(_createSyntheticToken(TokenType.SEMICOLON));
         }
-        return new BlockFunctionBody(keyword, star, parseBlock());
+        return astFactory.blockFunctionBody(keyword, star, parseBlock());
       } else if (_matchesString(_NATIVE)) {
         Token nativeToken = getAndAdvance();
         StringLiteral stringLiteral = null;
         if (_matches(TokenType.STRING)) {
           stringLiteral = _parseStringLiteralUnchecked();
         }
-        return new NativeFunctionBody(
+        return astFactory.nativeFunctionBody(
             nativeToken, stringLiteral, _expect(TokenType.SEMICOLON));
       } else {
         // Invalid function body
         _reportErrorForCurrentToken(emptyErrorCode);
-        return new EmptyFunctionBody(
-            _createSyntheticToken(TokenType.SEMICOLON));
+        return astFactory
+            .emptyFunctionBody(_createSyntheticToken(TokenType.SEMICOLON));
       }
     } finally {
       _inAsync = wasInAsync;
@@ -3170,7 +3188,7 @@
       keywordToken = getAndAdvance();
     }
     if (keywordToken != null && _matches(TokenType.OPEN_PAREN)) {
-      name = new SimpleIdentifier(keywordToken, isDeclaration: true);
+      name = astFactory.simpleIdentifier(keywordToken, isDeclaration: true);
       keywordToken = null;
       isGetter = false;
     } else {
@@ -3185,7 +3203,7 @@
       } else {
         _reportErrorForCurrentToken(
             ParserErrorCode.MISSING_FUNCTION_PARAMETERS);
-        parameters = new FormalParameterList(
+        parameters = astFactory.formalParameterList(
             _createSyntheticToken(TokenType.OPEN_PAREN),
             null,
             null,
@@ -3201,21 +3219,21 @@
       body = parseFunctionBody(
           false, ParserErrorCode.MISSING_FUNCTION_BODY, false);
     } else {
-      body = new EmptyFunctionBody(_expect(TokenType.SEMICOLON));
+      body = astFactory.emptyFunctionBody(_expect(TokenType.SEMICOLON));
     }
 //        if (!isStatement && matches(TokenType.SEMICOLON)) {
 //          // TODO(brianwilkerson) Improve this error message.
 //          reportError(ParserErrorCode.UNEXPECTED_TOKEN, currentToken.getLexeme());
 //          advance();
 //        }
-    return new FunctionDeclaration(
+    return astFactory.functionDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         externalKeyword,
         returnType,
         keywordToken,
         name,
-        new FunctionExpression(typeParameters, parameters, body));
+        astFactory.functionExpression(typeParameters, parameters, body));
   }
 
   /**
@@ -3245,7 +3263,7 @@
     _validateFormalParameterList(parameters);
     FunctionBody body =
         parseFunctionBody(false, ParserErrorCode.MISSING_FUNCTION_BODY, true);
-    return new FunctionExpression(typeParameters, parameters, body);
+    return astFactory.functionExpression(typeParameters, parameters, body);
   }
 
   /**
@@ -3281,7 +3299,7 @@
     if (externalKeyword != null && body is! EmptyFunctionBody) {
       _reportErrorForCurrentToken(ParserErrorCode.EXTERNAL_GETTER_WITH_BODY);
     }
-    return new MethodDeclaration(
+    return astFactory.methodDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         externalKeyword,
@@ -3321,7 +3339,7 @@
   Expression parseIfNullExpression() {
     Expression expression = parseLogicalOrExpression();
     while (_currentToken.type == TokenType.QUESTION_QUESTION) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseLogicalOrExpression());
     }
     return expression;
@@ -3347,7 +3365,7 @@
       elseKeyword = getAndAdvance();
       elseStatement = parseStatement2();
     }
-    return new IfStatement(ifKeyword, leftParenthesis, condition,
+    return astFactory.ifStatement(ifKeyword, leftParenthesis, condition,
         rightParenthesis, thenStatement, elseKeyword, elseStatement);
   }
 
@@ -3367,7 +3385,7 @@
       _mustNotBeNullable(typeName, ParserErrorCode.NULLABLE_TYPE_IN_IMPLEMENTS);
       interfaces.add(typeName);
     } while (_optional(TokenType.COMMA));
-    return new ImplementsClause(keyword, interfaces);
+    return astFactory.implementsClause(keyword, interfaces);
   }
 
   /**
@@ -3413,7 +3431,7 @@
     }
     List<Combinator> combinators = parseCombinators();
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new ImportDirective(
+    return astFactory.importDirective(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         importKeyword,
@@ -3452,7 +3470,7 @@
       TypeName type) {
     VariableDeclarationList fieldList =
         parseVariableDeclarationListAfterType(null, keyword, type);
-    return new FieldDeclaration(
+    return astFactory.fieldDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         staticKeyword,
@@ -3471,7 +3489,7 @@
   InstanceCreationExpression parseInstanceCreationExpression(Token keyword) {
     ConstructorName constructorName = parseConstructorName();
     ArgumentList argumentList = _parseArgumentListChecked();
-    return new InstanceCreationExpression(
+    return astFactory.instanceCreationExpression(
         keyword, constructorName, argumentList);
   }
 
@@ -3488,7 +3506,7 @@
     SimpleIdentifier label =
         _parseSimpleIdentifierUnchecked(isDeclaration: isDeclaration);
     Token colon = getAndAdvance();
-    return new Label(label, colon);
+    return astFactory.label(label, colon);
   }
 
   /**
@@ -3507,7 +3525,7 @@
     LibraryIdentifier libraryName = _parseLibraryName(
         ParserErrorCode.MISSING_NAME_IN_LIBRARY_DIRECTIVE, keyword);
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new LibraryDirective(commentAndMetadata.comment,
+    return astFactory.libraryDirective(commentAndMetadata.comment,
         commentAndMetadata.metadata, keyword, libraryName, semicolon);
   }
 
@@ -3523,7 +3541,7 @@
     while (_optional(TokenType.PERIOD)) {
       components.add(parseSimpleIdentifier());
     }
-    return new LibraryIdentifier(components);
+    return astFactory.libraryIdentifier(components);
   }
 
   /**
@@ -3541,12 +3559,12 @@
   ListLiteral parseListLiteral(Token modifier, TypeArgumentList typeArguments) {
     if (_matches(TokenType.INDEX)) {
       _splitIndex();
-      return new ListLiteral(
+      return astFactory.listLiteral(
           modifier, typeArguments, getAndAdvance(), null, getAndAdvance());
     }
     Token leftBracket = getAndAdvance();
     if (_matches(TokenType.CLOSE_SQUARE_BRACKET)) {
-      return new ListLiteral(
+      return astFactory.listLiteral(
           modifier, typeArguments, leftBracket, null, getAndAdvance());
     }
     bool wasInInitializer = _inInitializer;
@@ -3555,13 +3573,13 @@
       List<Expression> elements = <Expression>[parseExpression2()];
       while (_optional(TokenType.COMMA)) {
         if (_matches(TokenType.CLOSE_SQUARE_BRACKET)) {
-          return new ListLiteral(
+          return astFactory.listLiteral(
               modifier, typeArguments, leftBracket, elements, getAndAdvance());
         }
         elements.add(parseExpression2());
       }
       Token rightBracket = _expect(TokenType.CLOSE_SQUARE_BRACKET);
-      return new ListLiteral(
+      return astFactory.listLiteral(
           modifier, typeArguments, leftBracket, elements, rightBracket);
     } finally {
       _inInitializer = wasInInitializer;
@@ -3586,7 +3604,7 @@
       return parseListLiteral(modifier, typeArguments);
     }
     _reportErrorForCurrentToken(ParserErrorCode.EXPECTED_LIST_OR_MAP_LITERAL);
-    return new ListLiteral(
+    return astFactory.listLiteral(
         modifier,
         typeArguments,
         _createSyntheticToken(TokenType.OPEN_SQUARE_BRACKET),
@@ -3604,7 +3622,7 @@
   Expression parseLogicalAndExpression() {
     Expression expression = parseEqualityExpression();
     while (_currentToken.type == TokenType.AMPERSAND_AMPERSAND) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseEqualityExpression());
     }
     return expression;
@@ -3620,7 +3638,7 @@
   Expression parseLogicalOrExpression() {
     Expression expression = parseLogicalAndExpression();
     while (_currentToken.type == TokenType.BAR_BAR) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseLogicalAndExpression());
     }
     return expression;
@@ -3641,7 +3659,7 @@
   MapLiteral parseMapLiteral(Token modifier, TypeArgumentList typeArguments) {
     Token leftBracket = getAndAdvance();
     if (_matches(TokenType.CLOSE_CURLY_BRACKET)) {
-      return new MapLiteral(
+      return astFactory.mapLiteral(
           modifier, typeArguments, leftBracket, null, getAndAdvance());
     }
     bool wasInInitializer = _inInitializer;
@@ -3650,13 +3668,13 @@
       List<MapLiteralEntry> entries = <MapLiteralEntry>[parseMapLiteralEntry()];
       while (_optional(TokenType.COMMA)) {
         if (_matches(TokenType.CLOSE_CURLY_BRACKET)) {
-          return new MapLiteral(
+          return astFactory.mapLiteral(
               modifier, typeArguments, leftBracket, entries, getAndAdvance());
         }
         entries.add(parseMapLiteralEntry());
       }
       Token rightBracket = _expect(TokenType.CLOSE_CURLY_BRACKET);
-      return new MapLiteral(
+      return astFactory.mapLiteral(
           modifier, typeArguments, leftBracket, entries, rightBracket);
     } finally {
       _inInitializer = wasInInitializer;
@@ -3673,7 +3691,7 @@
     Expression key = parseExpression2();
     Token separator = _expect(TokenType.COLON);
     Expression value = parseExpression2();
-    return new MapLiteralEntry(key, separator, value);
+    return astFactory.mapLiteralEntry(key, separator, value);
   }
 
   /**
@@ -3773,12 +3791,12 @@
     Expression expression;
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type.isMultiplicativeOperator) {
-      expression = new SuperExpression(getAndAdvance());
+      expression = astFactory.superExpression(getAndAdvance());
     } else {
       expression = parseUnaryExpression();
     }
     while (_currentToken.type.isMultiplicativeOperator) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseUnaryExpression());
     }
     return expression;
@@ -3823,7 +3841,7 @@
       if (_tokenMatches(_peek(), TokenType.STRING)) {
         Token afterString = skipStringLiteral(_currentToken.next);
         if (afterString != null && afterString.type == TokenType.COLON) {
-          return new ExpressionStatement(
+          return astFactory.expressionStatement(
               parseExpression2(), _expect(TokenType.SEMICOLON));
         }
       }
@@ -3846,14 +3864,14 @@
       } else if (keyword == Keyword.IF) {
         return parseIfStatement();
       } else if (keyword == Keyword.RETHROW) {
-        return new ExpressionStatement(
+        return astFactory.expressionStatement(
             parseRethrowExpression(), _expect(TokenType.SEMICOLON));
       } else if (keyword == Keyword.RETURN) {
         return parseReturnStatement();
       } else if (keyword == Keyword.SWITCH) {
         return parseSwitchStatement();
       } else if (keyword == Keyword.THROW) {
-        return new ExpressionStatement(
+        return astFactory.expressionStatement(
             parseThrowExpression(), _expect(TokenType.SEMICOLON));
       } else if (keyword == Keyword.TRY) {
         return parseTryStatement();
@@ -3863,8 +3881,8 @@
         return parseVariableDeclarationStatementAfterMetadata(
             commentAndMetadata);
       } else if (keyword == Keyword.VOID) {
-        TypeName returnType =
-            new TypeName(new SimpleIdentifier(getAndAdvance()), null);
+        TypeName returnType = astFactory.typeName(
+            astFactory.simpleIdentifier(getAndAdvance()), null);
         Token next = _currentToken.next;
         if (_matchesIdentifier() &&
             next.matchesAny(const <TokenType>[
@@ -3902,7 +3920,8 @@
           }
           _reportErrorForCurrentToken(ParserErrorCode.MISSING_STATEMENT);
           // TODO(brianwilkerson) Recover from this error.
-          return new EmptyStatement(_createSyntheticToken(TokenType.SEMICOLON));
+          return astFactory
+              .emptyStatement(_createSyntheticToken(TokenType.SEMICOLON));
         }
       } else if (keyword == Keyword.CONST) {
         Token next = _currentToken.next;
@@ -3912,7 +3931,7 @@
           TokenType.OPEN_SQUARE_BRACKET,
           TokenType.INDEX
         ])) {
-          return new ExpressionStatement(
+          return astFactory.expressionStatement(
               parseExpression2(), _expect(TokenType.SEMICOLON));
         } else if (_tokenMatches(next, TokenType.IDENTIFIER)) {
           Token afterType = skipTypeName(next);
@@ -3921,7 +3940,7 @@
                 (_tokenMatches(afterType, TokenType.PERIOD) &&
                     _tokenMatches(afterType.next, TokenType.IDENTIFIER) &&
                     _tokenMatches(afterType.next.next, TokenType.OPEN_PAREN))) {
-              return new ExpressionStatement(
+              return astFactory.expressionStatement(
                   parseExpression2(), _expect(TokenType.SEMICOLON));
             }
           }
@@ -3934,14 +3953,15 @@
           keyword == Keyword.NULL ||
           keyword == Keyword.SUPER ||
           keyword == Keyword.THIS) {
-        return new ExpressionStatement(
+        return astFactory.expressionStatement(
             parseExpression2(), _expect(TokenType.SEMICOLON));
       } else {
         //
         // We have found an error of some kind. Try to recover.
         //
         _reportErrorForCurrentToken(ParserErrorCode.MISSING_STATEMENT);
-        return new EmptyStatement(_createSyntheticToken(TokenType.SEMICOLON));
+        return astFactory
+            .emptyStatement(_createSyntheticToken(TokenType.SEMICOLON));
       }
     } else if (_inGenerator && _matchesString(_YIELD)) {
       return parseYieldStatement();
@@ -3949,7 +3969,7 @@
       if (_tokenMatchesKeyword(_peek(), Keyword.FOR)) {
         return parseForStatement();
       }
-      return new ExpressionStatement(
+      return astFactory.expressionStatement(
           parseExpression2(), _expect(TokenType.SEMICOLON));
     } else if (_matchesString(_AWAIT) &&
         _tokenMatchesKeyword(_peek(), Keyword.FOR)) {
@@ -3968,9 +3988,10 @@
       return parseFunctionDeclarationStatement();
     } else if (type == TokenType.CLOSE_CURLY_BRACKET) {
       _reportErrorForCurrentToken(ParserErrorCode.MISSING_STATEMENT);
-      return new EmptyStatement(_createSyntheticToken(TokenType.SEMICOLON));
+      return astFactory
+          .emptyStatement(_createSyntheticToken(TokenType.SEMICOLON));
     } else {
-      return new ExpressionStatement(
+      return astFactory.expressionStatement(
           parseExpression2(), _expect(TokenType.SEMICOLON));
     }
   }
@@ -4016,16 +4037,16 @@
         if (enableNnbd && _matches(TokenType.QUESTION)) {
           question = getAndAdvance();
         }
-        return new FunctionTypedFormalParameter(
+        return astFactory.functionTypedFormalParameter(
             commentAndMetadata.comment,
             commentAndMetadata.metadata,
             holder.type,
-            new SimpleIdentifier(identifier.token, isDeclaration: true),
+            astFactory.simpleIdentifier(identifier.token, isDeclaration: true),
             typeParameters,
             parameters,
             question: question);
       } else {
-        return new FieldFormalParameter(
+        return astFactory.fieldFormalParameter(
             commentAndMetadata.comment,
             commentAndMetadata.metadata,
             holder.keyword,
@@ -4055,7 +4076,7 @@
       // TODO(brianwilkerson) If there are type parameters but no parameters,
       // should we create a synthetic empty parameter list here so we can
       // capture the type parameters?
-      return new FieldFormalParameter(
+      return astFactory.fieldFormalParameter(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
           holder.keyword,
@@ -4066,12 +4087,12 @@
           null,
           null);
     }
-    return new SimpleFormalParameter(
+    return astFactory.simpleFormalParameter(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         holder.keyword,
         holder.type,
-        new SimpleIdentifier(identifier.token, isDeclaration: true));
+        astFactory.simpleIdentifier(identifier.token, isDeclaration: true));
   }
 
   /**
@@ -4147,14 +4168,14 @@
           ArgumentList argumentList = parseArgumentList();
           Expression currentOperand = operand;
           if (currentOperand is PropertyAccess) {
-            operand = new MethodInvocation(
+            operand = astFactory.methodInvocation(
                 currentOperand.target,
                 currentOperand.operator,
                 currentOperand.propertyName,
                 typeArguments,
                 argumentList);
           } else {
-            operand = new FunctionExpressionInvocation(
+            operand = astFactory.functionExpressionInvocation(
                 operand, typeArguments, argumentList);
           }
         } else {
@@ -4173,7 +4194,7 @@
     }
     _ensureAssignable(operand);
     Token operator = getAndAdvance();
-    return new PostfixExpression(operand, operator);
+    return astFactory.postfixExpression(operand, operator);
   }
 
   /**
@@ -4236,25 +4257,25 @@
       } on FormatException {
         // The invalid format should have been reported by the scanner.
       }
-      return new IntegerLiteral(token, value);
+      return astFactory.integerLiteral(token, value);
     }
     Keyword keyword = _currentToken.keyword;
     if (keyword == Keyword.NULL) {
-      return new NullLiteral(getAndAdvance());
+      return astFactory.nullLiteral(getAndAdvance());
     } else if (keyword == Keyword.NEW) {
       return parseNewExpression();
     } else if (keyword == Keyword.THIS) {
-      return new ThisExpression(getAndAdvance());
+      return astFactory.thisExpression(getAndAdvance());
     } else if (keyword == Keyword.SUPER) {
       // TODO(paulberry): verify with Gilad that "super" must be followed by
       // unconditionalAssignableSelector in this case.
       return parseAssignableSelector(
-          new SuperExpression(getAndAdvance()), false,
+          astFactory.superExpression(getAndAdvance()), false,
           allowConditional: false);
     } else if (keyword == Keyword.FALSE) {
-      return new BooleanLiteral(getAndAdvance(), false);
+      return astFactory.booleanLiteral(getAndAdvance(), false);
     } else if (keyword == Keyword.TRUE) {
-      return new BooleanLiteral(getAndAdvance(), true);
+      return astFactory.booleanLiteral(getAndAdvance(), true);
     }
     if (type == TokenType.DOUBLE) {
       Token token = getAndAdvance();
@@ -4264,7 +4285,7 @@
       } on FormatException {
         // The invalid format should have been reported by the scanner.
       }
-      return new DoubleLiteral(token, value);
+      return astFactory.doubleLiteral(token, value);
     } else if (type == TokenType.HEXADECIMAL) {
       Token token = getAndAdvance();
       int value = null;
@@ -4273,7 +4294,7 @@
       } on FormatException {
         // The invalid format should have been reported by the scanner.
       }
-      return new IntegerLiteral(token, value);
+      return astFactory.integerLiteral(token, value);
     } else if (keyword == Keyword.CONST) {
       return parseConstExpression();
     } else if (type == TokenType.OPEN_PAREN) {
@@ -4286,7 +4307,7 @@
       try {
         Expression expression = parseExpression2();
         Token rightParenthesis = _expect(TokenType.CLOSE_PAREN);
-        return new ParenthesizedExpression(
+        return astFactory.parenthesizedExpression(
             leftParenthesis, expression, rightParenthesis);
       } finally {
         _inInitializer = wasInInitializer;
@@ -4351,7 +4372,7 @@
       }
     }
     ArgumentList argumentList = _parseArgumentListChecked();
-    return new RedirectingConstructorInvocation(
+    return astFactory.redirectingConstructorInvocation(
         keyword, period, constructorName, argumentList);
   }
 
@@ -4366,27 +4387,28 @@
   Expression parseRelationalExpression() {
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type.isRelationalOperator) {
-      Expression expression = new SuperExpression(getAndAdvance());
+      Expression expression = astFactory.superExpression(getAndAdvance());
       Token operator = getAndAdvance();
-      return new BinaryExpression(
+      return astFactory.binaryExpression(
           expression, operator, parseBitwiseOrExpression());
     }
     Expression expression = parseBitwiseOrExpression();
     Keyword keyword = _currentToken.keyword;
     if (keyword == Keyword.AS) {
       Token asOperator = getAndAdvance();
-      return new AsExpression(expression, asOperator, parseTypeName(true));
+      return astFactory.asExpression(
+          expression, asOperator, parseTypeName(true));
     } else if (keyword == Keyword.IS) {
       Token isOperator = getAndAdvance();
       Token notOperator = null;
       if (_matches(TokenType.BANG)) {
         notOperator = getAndAdvance();
       }
-      return new IsExpression(
+      return astFactory.isExpression(
           expression, isOperator, notOperator, parseTypeName(true));
     } else if (_currentToken.type.isRelationalOperator) {
       Token operator = getAndAdvance();
-      return new BinaryExpression(
+      return astFactory.binaryExpression(
           expression, operator, parseBitwiseOrExpression());
     }
     return expression;
@@ -4400,7 +4422,8 @@
    *     rethrowExpression ::=
    *         'rethrow'
    */
-  Expression parseRethrowExpression() => new RethrowExpression(getAndAdvance());
+  Expression parseRethrowExpression() =>
+      astFactory.rethrowExpression(getAndAdvance());
 
   /**
    * Parse a return statement. Return the return statement that was parsed.
@@ -4413,11 +4436,11 @@
   Statement parseReturnStatement() {
     Token returnKeyword = getAndAdvance();
     if (_matches(TokenType.SEMICOLON)) {
-      return new ReturnStatement(returnKeyword, null, getAndAdvance());
+      return astFactory.returnStatement(returnKeyword, null, getAndAdvance());
     }
     Expression expression = parseExpression2();
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new ReturnStatement(returnKeyword, expression, semicolon);
+    return astFactory.returnStatement(returnKeyword, expression, semicolon);
   }
 
   /**
@@ -4429,7 +4452,8 @@
    */
   TypeName parseReturnType() {
     if (_currentToken.keyword == Keyword.VOID) {
-      return new TypeName(new SimpleIdentifier(getAndAdvance()), null);
+      return astFactory.typeName(
+          astFactory.simpleIdentifier(getAndAdvance()), null);
     } else {
       return parseTypeName(false);
     }
@@ -4464,7 +4488,7 @@
     if (externalKeyword != null && body is! EmptyFunctionBody) {
       _reportErrorForCurrentToken(ParserErrorCode.EXTERNAL_SETTER_WITH_BODY);
     }
-    return new MethodDeclaration(
+    return astFactory.methodDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         externalKeyword,
@@ -4489,12 +4513,12 @@
     Expression expression;
     if (_currentToken.keyword == Keyword.SUPER &&
         _currentToken.next.type.isShiftOperator) {
-      expression = new SuperExpression(getAndAdvance());
+      expression = astFactory.superExpression(getAndAdvance());
     } else {
       expression = parseAdditiveExpression();
     }
     while (_currentToken.type.isShiftOperator) {
-      expression = new BinaryExpression(
+      expression = astFactory.binaryExpression(
           expression, getAndAdvance(), parseAdditiveExpression());
     }
     return expression;
@@ -4544,7 +4568,7 @@
     if (labels == null) {
       return statement;
     }
-    return new LabeledStatement(labels, statement);
+    return astFactory.labeledStatement(labels, statement);
   }
 
   /**
@@ -4590,7 +4614,7 @@
       constructorName = parseSimpleIdentifier();
     }
     ArgumentList argumentList = _parseArgumentListChecked();
-    return new SuperConstructorInvocation(
+    return astFactory.superConstructorInvocation(
         keyword, period, constructorName, argumentList);
   }
 
@@ -4635,15 +4659,15 @@
             definedLabels.add(label);
           }
           Token colon = getAndAdvance();
-          labels.add(new Label(identifier, colon));
+          labels.add(astFactory.label(identifier, colon));
         }
         Keyword keyword = _currentToken.keyword;
         if (keyword == Keyword.CASE) {
           Token caseKeyword = getAndAdvance();
           Expression caseExpression = parseExpression2();
           Token colon = _expect(TokenType.COLON);
-          members.add(new SwitchCase(labels, caseKeyword, caseExpression, colon,
-              _parseStatementList()));
+          members.add(astFactory.switchCase(labels, caseKeyword, caseExpression,
+              colon, _parseStatementList()));
           if (defaultKeyword != null) {
             _reportErrorForToken(
                 ParserErrorCode.SWITCH_HAS_CASE_AFTER_DEFAULT_CASE,
@@ -4656,7 +4680,7 @@
           }
           defaultKeyword = getAndAdvance();
           Token colon = _expect(TokenType.COLON);
-          members.add(new SwitchDefault(
+          members.add(astFactory.switchDefault(
               labels, defaultKeyword, colon, _parseStatementList()));
         } else {
           // We need to advance, otherwise we could end up in an infinite loop,
@@ -4679,7 +4703,7 @@
         type = _currentToken.type;
       }
       Token rightBracket = _expect(TokenType.CLOSE_CURLY_BRACKET);
-      return new SwitchStatement(keyword, leftParenthesis, expression,
+      return astFactory.switchStatement(keyword, leftParenthesis, expression,
           rightParenthesis, leftBracket, members, rightBracket);
     } finally {
       _inSwitch = wasInSwitch;
@@ -4716,7 +4740,7 @@
       _reportErrorForCurrentToken(ParserErrorCode.MISSING_IDENTIFIER);
       components.add(_createSyntheticToken(TokenType.IDENTIFIER));
     }
-    return new SymbolLiteral(poundSign, components);
+    return astFactory.symbolLiteral(poundSign, components);
   }
 
   /**
@@ -4733,10 +4757,10 @@
     if (type == TokenType.SEMICOLON || type == TokenType.CLOSE_PAREN) {
       _reportErrorForToken(
           ParserErrorCode.MISSING_EXPRESSION_IN_THROW, _currentToken);
-      return new ThrowExpression(keyword, createSyntheticIdentifier());
+      return astFactory.throwExpression(keyword, createSyntheticIdentifier());
     }
     Expression expression = parseExpression2();
-    return new ThrowExpression(keyword, expression);
+    return astFactory.throwExpression(keyword, expression);
   }
 
   /**
@@ -4753,10 +4777,10 @@
     if (type == TokenType.SEMICOLON || type == TokenType.CLOSE_PAREN) {
       _reportErrorForToken(
           ParserErrorCode.MISSING_EXPRESSION_IN_THROW, _currentToken);
-      return new ThrowExpression(keyword, createSyntheticIdentifier());
+      return astFactory.throwExpression(keyword, createSyntheticIdentifier());
     }
     Expression expression = parseExpressionWithoutCascade();
-    return new ThrowExpression(keyword, expression);
+    return astFactory.throwExpression(keyword, expression);
   }
 
   /**
@@ -4806,7 +4830,7 @@
         rightParenthesis = _expect(TokenType.CLOSE_PAREN);
       }
       Block catchBody = _parseBlockChecked();
-      catchClauses.add(new CatchClause(
+      catchClauses.add(astFactory.catchClause(
           onKeyword,
           exceptionType,
           catchKeyword,
@@ -4824,7 +4848,7 @@
     } else if (catchClauses.isEmpty) {
       _reportErrorForCurrentToken(ParserErrorCode.MISSING_CATCH_OR_FINALLY);
     }
-    return new TryStatement(
+    return astFactory.tryStatement(
         tryKeyword, body, catchClauses, finallyKeyword, finallyClause);
   }
 
@@ -4896,7 +4920,7 @@
       arguments.add(parseTypeName(false));
     }
     Token rightBracket = _expectGt();
-    return new TypeArgumentList(leftBracket, arguments, rightBracket);
+    return astFactory.typeArgumentList(leftBracket, arguments, rightBracket);
   }
 
   /**
@@ -4931,10 +4955,10 @@
     if (_matchesKeyword(Keyword.EXTENDS)) {
       Token keyword = getAndAdvance();
       TypeName bound = parseTypeName(false);
-      return new TypeParameter(commentAndMetadata.comment,
+      return astFactory.typeParameter(commentAndMetadata.comment,
           commentAndMetadata.metadata, name, keyword, bound);
     }
-    return new TypeParameter(commentAndMetadata.comment,
+    return astFactory.typeParameter(commentAndMetadata.comment,
         commentAndMetadata.metadata, name, null, null);
   }
 
@@ -4954,7 +4978,8 @@
       typeParameters.add(parseTypeParameter());
     }
     Token rightBracket = _expectGt();
-    return new TypeParameterList(leftBracket, typeParameters, rightBracket);
+    return astFactory.typeParameterList(
+        leftBracket, typeParameters, rightBracket);
   }
 
   /**
@@ -4982,12 +5007,12 @@
           // --> "prefixOperator postfixExpression"
           // --> "prefixOperator primary                    selector*"
           // --> "prefixOperator 'super' assignableSelector selector*"
-          return new PrefixExpression(operator, parseUnaryExpression());
+          return astFactory.prefixExpression(operator, parseUnaryExpression());
         }
-        return new PrefixExpression(
-            operator, new SuperExpression(getAndAdvance()));
+        return astFactory.prefixExpression(
+            operator, astFactory.superExpression(getAndAdvance()));
       }
-      return new PrefixExpression(operator, parseUnaryExpression());
+      return astFactory.prefixExpression(operator, parseUnaryExpression());
     } else if (_currentToken.type.isIncrementOperator) {
       Token operator = getAndAdvance();
       if (_matchesKeyword(Keyword.SUPER)) {
@@ -4995,7 +5020,7 @@
         if (nextType == TokenType.OPEN_SQUARE_BRACKET ||
             nextType == TokenType.PERIOD) {
           // --> "prefixOperator 'super' assignableSelector selector*"
-          return new PrefixExpression(operator, parseUnaryExpression());
+          return astFactory.prefixExpression(operator, parseUnaryExpression());
         }
         //
         // Even though it is not valid to use an incrementing operator
@@ -5011,18 +5036,18 @@
           secondOperator.setNext(_currentToken);
           firstOperator.setNext(secondOperator);
           operator.previous.setNext(firstOperator);
-          return new PrefixExpression(
+          return astFactory.prefixExpression(
               firstOperator,
-              new PrefixExpression(
-                  secondOperator, new SuperExpression(getAndAdvance())));
+              astFactory.prefixExpression(
+                  secondOperator, astFactory.superExpression(getAndAdvance())));
         }
         // Invalid operator before 'super'
         _reportErrorForCurrentToken(
             ParserErrorCode.INVALID_OPERATOR_FOR_SUPER, [operator.lexeme]);
-        return new PrefixExpression(
-            operator, new SuperExpression(getAndAdvance()));
+        return astFactory.prefixExpression(
+            operator, astFactory.superExpression(getAndAdvance()));
       }
-      return new PrefixExpression(
+      return astFactory.prefixExpression(
           operator, _parseAssignableExpressionNotStartingWithSuper(false));
     } else if (type == TokenType.PLUS) {
       _reportErrorForCurrentToken(ParserErrorCode.MISSING_IDENTIFIER);
@@ -5057,7 +5082,7 @@
       equals = getAndAdvance();
       initializer = parseExpression2();
     }
-    return new VariableDeclaration(name, equals, initializer);
+    return astFactory.variableDeclaration(name, equals, initializer);
   }
 
   /**
@@ -5099,7 +5124,7 @@
     while (_optional(TokenType.COMMA)) {
       variables.add(parseVariableDeclaration());
     }
-    return new VariableDeclarationList(commentAndMetadata?.comment,
+    return astFactory.variableDeclarationList(commentAndMetadata?.comment,
         commentAndMetadata?.metadata, keyword, type, variables);
   }
 
@@ -5124,7 +5149,7 @@
 //          }
 //        }
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new VariableDeclarationStatement(variableList, semicolon);
+    return astFactory.variableDeclarationStatement(variableList, semicolon);
   }
 
   /**
@@ -5144,7 +5169,7 @@
       Expression condition = parseExpression2();
       Token rightParenthesis = _expect(TokenType.CLOSE_PAREN);
       Statement body = parseStatement2();
-      return new WhileStatement(
+      return astFactory.whileStatement(
           keyword, leftParenthesis, condition, rightParenthesis, body);
     } finally {
       _inLoop = wasInLoop;
@@ -5167,7 +5192,7 @@
       _mustNotBeNullable(typeName, ParserErrorCode.NULLABLE_TYPE_IN_WITH);
       types.add(typeName);
     } while (_optional(TokenType.COMMA));
-    return new WithClause(withKeyword, types);
+    return astFactory.withClause(withKeyword, types);
   }
 
   /**
@@ -5186,7 +5211,7 @@
     }
     Expression expression = parseExpression2();
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new YieldStatement(yieldToken, star, expression, semicolon);
+    return astFactory.yieldStatement(yieldToken, star, expression, semicolon);
   }
 
   /**
@@ -5416,14 +5441,14 @@
    * captures the components of the given method declaration).
    */
   FunctionDeclaration _convertToFunctionDeclaration(MethodDeclaration method) =>
-      new FunctionDeclaration(
+      astFactory.functionDeclaration(
           method.documentationComment,
           method.metadata,
           method.externalKeyword,
           method.returnType,
           method.propertyKeyword,
           method.name,
-          new FunctionExpression(
+          astFactory.functionExpression(
               method.typeParameters, method.parameters, method.body));
 
   /**
@@ -5984,8 +6009,8 @@
         ParserErrorCode.EXPECTED_TOKEN, [TokenType.OPEN_PAREN.lexeme]);
     // Recovery: Look to see whether there is a close paren that isn't matched
     // to an open paren and if so parse the list of arguments as normal.
-    return new ArgumentList(_createSyntheticToken(TokenType.OPEN_PAREN), null,
-        _createSyntheticToken(TokenType.CLOSE_PAREN));
+    return astFactory.argumentList(_createSyntheticToken(TokenType.OPEN_PAREN),
+        null, _createSyntheticToken(TokenType.CLOSE_PAREN));
   }
 
   /**
@@ -6007,7 +6032,7 @@
       message = parseExpression2();
     }
     Token rightParen = _expect(TokenType.CLOSE_PAREN);
-    return new AssertInitializer(
+    return astFactory.assertInitializer(
         keyword, leftParen, expression, comma, message, rightParen);
   }
 
@@ -6032,24 +6057,24 @@
         ArgumentList argumentList = parseArgumentList();
         Expression currentExpression = expression;
         if (currentExpression is SimpleIdentifier) {
-          expression = new MethodInvocation(
+          expression = astFactory.methodInvocation(
               null, null, currentExpression, typeArguments, argumentList);
         } else if (currentExpression is PrefixedIdentifier) {
-          expression = new MethodInvocation(
+          expression = astFactory.methodInvocation(
               currentExpression.prefix,
               currentExpression.period,
               currentExpression.identifier,
               typeArguments,
               argumentList);
         } else if (currentExpression is PropertyAccess) {
-          expression = new MethodInvocation(
+          expression = astFactory.methodInvocation(
               currentExpression.target,
               currentExpression.operator,
               currentExpression.propertyName,
               typeArguments,
               argumentList);
         } else {
-          expression = new FunctionExpressionInvocation(
+          expression = astFactory.functionExpressionInvocation(
               expression, typeArguments, argumentList);
         }
         if (!primaryAllowed) {
@@ -6061,7 +6086,7 @@
       if (identical(selectorExpression, expression)) {
         if (!isOptional && (expression is PrefixedIdentifier)) {
           PrefixedIdentifier identifier = expression as PrefixedIdentifier;
-          expression = new PropertyAccess(
+          expression = astFactory.propertyAccess(
               identifier.prefix, identifier.period, identifier.identifier);
         }
         return expression;
@@ -6087,8 +6112,8 @@
         ParserErrorCode.EXPECTED_TOKEN, [TokenType.OPEN_CURLY_BRACKET.lexeme]);
     // Recovery: Check for an unmatched closing curly bracket and parse
     // statements until it is reached.
-    return new Block(_createSyntheticToken(TokenType.OPEN_CURLY_BRACKET), null,
-        _createSyntheticToken(TokenType.CLOSE_CURLY_BRACKET));
+    return astFactory.block(_createSyntheticToken(TokenType.OPEN_CURLY_BRACKET),
+        null, _createSyntheticToken(TokenType.CLOSE_CURLY_BRACKET));
   }
 
   /**
@@ -6180,7 +6205,7 @@
       }
       semicolon = _createSyntheticToken(TokenType.SEMICOLON);
     }
-    return new ClassTypeAlias(
+    return astFactory.classTypeAlias(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         classKeyword,
@@ -6258,7 +6283,7 @@
     if (_matches(TokenType.EQ)) {
       separator = getAndAdvance();
       redirectedConstructor = parseConstructorName();
-      body = new EmptyFunctionBody(_expect(TokenType.SEMICOLON));
+      body = astFactory.emptyFunctionBody(_expect(TokenType.SEMICOLON));
       if (factoryKeyword == null) {
         _reportErrorForNode(
             ParserErrorCode.REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR,
@@ -6292,7 +6317,7 @@
         }
       }
     }
-    return new ConstructorDeclaration(
+    return astFactory.constructorDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         externalKeyword,
@@ -6334,7 +6359,7 @@
       _reportErrorForNode(ParserErrorCode.ANNOTATION_ON_ENUM_CONSTANT,
           commentAndMetadata.metadata[0]);
     }
-    return new EnumConstantDeclaration(
+    return astFactory.enumConstantDeclaration(
         commentAndMetadata.comment, commentAndMetadata.metadata, name);
   }
 
@@ -6345,7 +6370,7 @@
   FormalParameterList _parseFormalParameterListAfterParen(
       Token leftParenthesis) {
     if (_matches(TokenType.CLOSE_PAREN)) {
-      return new FormalParameterList(
+      return astFactory.formalParameterList(
           leftParenthesis, null, null, null, getAndAdvance());
     }
     //
@@ -6495,7 +6520,7 @@
     //
     leftSquareBracket ??= leftCurlyBracket;
     rightSquareBracket ??= rightCurlyBracket;
-    return new FormalParameterList(leftParenthesis, parameters,
+    return astFactory.formalParameterList(leftParenthesis, parameters,
         leftSquareBracket, rightSquareBracket, rightParenthesis);
   }
 
@@ -6532,7 +6557,7 @@
             ParserErrorCode.SETTER_IN_FUNCTION, propertyKeyword);
       }
     }
-    return new FunctionDeclarationStatement(declaration);
+    return astFactory.functionDeclarationStatement(declaration);
   }
 
   /**
@@ -6560,14 +6585,14 @@
     TokenType type = _currentToken.type;
     if (type == TokenType.SEMICOLON || type == TokenType.EOF) {
       _reportErrorForCurrentToken(ParserErrorCode.MISSING_TYPEDEF_PARAMETERS);
-      FormalParameterList parameters = new FormalParameterList(
+      FormalParameterList parameters = astFactory.formalParameterList(
           _createSyntheticToken(TokenType.OPEN_PAREN),
           null,
           null,
           null,
           _createSyntheticToken(TokenType.CLOSE_PAREN));
       Token semicolon = _expect(TokenType.SEMICOLON);
-      return new FunctionTypeAlias(
+      return astFactory.functionTypeAlias(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
           keyword,
@@ -6580,7 +6605,7 @@
       FormalParameterList parameters = _parseFormalParameterListUnchecked();
       _validateFormalParameterList(parameters);
       Token semicolon = _expect(TokenType.SEMICOLON);
-      return new FunctionTypeAlias(
+      return astFactory.functionTypeAlias(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
           keyword,
@@ -6594,15 +6619,19 @@
       // Recovery: At the very least we should skip to the start of the next
       // valid compilation unit member, allowing for the possibility of finding
       // the typedef parameters before that point.
-      return new FunctionTypeAlias(
+      return astFactory.functionTypeAlias(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
           keyword,
           returnType,
           name,
           typeParameters,
-          new FormalParameterList(_createSyntheticToken(TokenType.OPEN_PAREN),
-              null, null, null, _createSyntheticToken(TokenType.CLOSE_PAREN)),
+          astFactory.formalParameterList(
+              _createSyntheticToken(TokenType.OPEN_PAREN),
+              null,
+              null,
+              null,
+              _createSyntheticToken(TokenType.CLOSE_PAREN)),
           _createSyntheticToken(TokenType.SEMICOLON));
     }
   }
@@ -6658,8 +6687,8 @@
     } else {
       _reportErrorForToken(missingNameError, missingNameToken);
     }
-    return new LibraryIdentifier(
-        <SimpleIdentifier>[createSyntheticIdentifier()]);
+    return astFactory
+        .libraryIdentifier(<SimpleIdentifier>[createSyntheticIdentifier()]);
   }
 
   /**
@@ -6696,7 +6725,7 @@
         _reportErrorForNode(ParserErrorCode.ABSTRACT_STATIC_METHOD, body);
       }
     }
-    return new MethodDeclaration(
+    return astFactory.methodDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         externalKeyword,
@@ -6737,7 +6766,7 @@
         (type == TokenType.OPEN_CURLY_BRACKET || type == TokenType.FUNCTION)) {
       _reportErrorForToken(
           ParserErrorCode.MISSING_METHOD_PARAMETERS, _currentToken.previous);
-      parameters = new FormalParameterList(
+      parameters = astFactory.formalParameterList(
           _createSyntheticToken(TokenType.OPEN_PAREN),
           null,
           null,
@@ -6768,7 +6797,7 @@
   NativeClause _parseNativeClause() {
     Token keyword = getAndAdvance();
     StringLiteral name = parseStringLiteral();
-    return new NativeClause(keyword, name);
+    return astFactory.nativeClause(keyword, name);
   }
 
   /**
@@ -6795,7 +6824,7 @@
           ParserErrorCode.NON_USER_DEFINABLE_OPERATOR, [_currentToken.lexeme]);
     }
     SimpleIdentifier name =
-        new SimpleIdentifier(getAndAdvance(), isDeclaration: true);
+        astFactory.simpleIdentifier(getAndAdvance(), isDeclaration: true);
     if (_matches(TokenType.EQ)) {
       Token previous = _currentToken.previous;
       if ((_tokenMatches(previous, TokenType.EQ_EQ) ||
@@ -6813,7 +6842,7 @@
     if (externalKeyword != null && body is! EmptyFunctionBody) {
       _reportErrorForCurrentToken(ParserErrorCode.EXTERNAL_OPERATOR_WITH_BODY);
     }
-    return new MethodDeclaration(
+    return astFactory.methodDeclaration(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         externalKeyword,
@@ -6838,7 +6867,8 @@
     }
     Keyword keyword = _currentToken.keyword;
     if (keyword == Keyword.VOID) {
-      return new TypeName(new SimpleIdentifier(getAndAdvance()), null);
+      return astFactory.typeName(
+          astFactory.simpleIdentifier(getAndAdvance()), null);
     } else if (_matchesIdentifier()) {
       Token next = _peek();
       if (keyword != Keyword.GET &&
@@ -6900,7 +6930,7 @@
     Token partKeyword = getAndAdvance();
     StringLiteral partUri = _parseUri();
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new PartDirective(commentAndMetadata.comment,
+    return astFactory.partDirective(commentAndMetadata.comment,
         commentAndMetadata.metadata, partKeyword, partUri, semicolon);
   }
 
@@ -6921,7 +6951,7 @@
     if (enableUriInPartOf && _matches(TokenType.STRING)) {
       StringLiteral libraryUri = _parseUri();
       Token semicolon = _expect(TokenType.SEMICOLON);
-      return new PartOfDirective(
+      return astFactory.partOfDirective(
           commentAndMetadata.comment,
           commentAndMetadata.metadata,
           partKeyword,
@@ -6933,7 +6963,7 @@
     LibraryIdentifier libraryName = _parseLibraryName(
         ParserErrorCode.MISSING_NAME_IN_PART_OF_DIRECTIVE, ofKeyword);
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new PartOfDirective(
+    return astFactory.partOfDirective(
         commentAndMetadata.comment,
         commentAndMetadata.metadata,
         partKeyword,
@@ -6957,7 +6987,7 @@
     }
     Token period = getAndAdvance();
     SimpleIdentifier qualified = parseSimpleIdentifier();
-    return new PrefixedIdentifier(qualifier, period, qualified);
+    return astFactory.prefixedIdentifier(qualifier, period, qualified);
   }
 
   /**
@@ -6990,7 +7020,8 @@
       _reportErrorForCurrentToken(
           ParserErrorCode.ASYNC_KEYWORD_USED_AS_IDENTIFIER);
     }
-    return new SimpleIdentifier(getAndAdvance(), isDeclaration: isDeclaration);
+    return astFactory.simpleIdentifier(getAndAdvance(),
+        isDeclaration: isDeclaration);
   }
 
   /**
@@ -7029,7 +7060,7 @@
    */
   StringInterpolation _parseStringInterpolation(Token string) {
     List<InterpolationElement> elements = <InterpolationElement>[
-      new InterpolationString(
+      astFactory.interpolationString(
           string, computeStringValue(string.lexeme, true, false))
     ];
     bool hasMore = true;
@@ -7042,8 +7073,8 @@
         try {
           Expression expression = parseExpression2();
           Token rightBracket = _expect(TokenType.CLOSE_CURLY_BRACKET);
-          elements.add(
-              new InterpolationExpression(openToken, expression, rightBracket));
+          elements.add(astFactory.interpolationExpression(
+              openToken, expression, rightBracket));
         } finally {
           _inInitializer = wasInInitializer;
         }
@@ -7051,24 +7082,25 @@
         Token openToken = getAndAdvance();
         Expression expression = null;
         if (_matchesKeyword(Keyword.THIS)) {
-          expression = new ThisExpression(getAndAdvance());
+          expression = astFactory.thisExpression(getAndAdvance());
         } else {
           expression = parseSimpleIdentifier();
         }
-        elements.add(new InterpolationExpression(openToken, expression, null));
+        elements.add(
+            astFactory.interpolationExpression(openToken, expression, null));
       }
       if (_matches(TokenType.STRING)) {
         string = getAndAdvance();
         isExpression = _matches(TokenType.STRING_INTERPOLATION_EXPRESSION);
         hasMore =
             isExpression || _matches(TokenType.STRING_INTERPOLATION_IDENTIFIER);
-        elements.add(new InterpolationString(
+        elements.add(astFactory.interpolationString(
             string, computeStringValue(string.lexeme, false, !hasMore)));
       } else {
         hasMore = false;
       }
     }
-    return new StringInterpolation(elements);
+    return astFactory.stringInterpolation(elements);
   }
 
   /**
@@ -7088,11 +7120,13 @@
           _matches(TokenType.STRING_INTERPOLATION_IDENTIFIER)) {
         strings.add(_parseStringInterpolation(string));
       } else {
-        strings.add(new SimpleStringLiteral(
+        strings.add(astFactory.simpleStringLiteral(
             string, computeStringValue(string.lexeme, true, true)));
       }
     } while (_matches(TokenType.STRING));
-    return strings.length == 1 ? strings[0] : new AdjacentStrings(strings);
+    return strings.length == 1
+        ? strings[0]
+        : astFactory.adjacentStrings(strings);
   }
 
   TypeName _parseTypeName(bool inExpression) {
@@ -7101,7 +7135,7 @@
       typeName = _parsePrefixedIdentifierUnchecked();
     } else if (_matchesKeyword(Keyword.VAR)) {
       _reportErrorForCurrentToken(ParserErrorCode.VAR_AS_TYPE_NAME);
-      typeName = new SimpleIdentifier(getAndAdvance());
+      typeName = astFactory.simpleIdentifier(getAndAdvance());
     } else {
       typeName = createSyntheticIdentifier();
       _reportErrorForCurrentToken(ParserErrorCode.EXPECTED_TYPE_NAME);
@@ -7113,7 +7147,7 @@
         question = getAndAdvance();
       }
     }
-    return new TypeName(typeName, typeArguments, question: question);
+    return astFactory.typeName(typeName, typeArguments, question: question);
   }
 
   /**
@@ -7132,7 +7166,7 @@
     // TODO(jmesserly): this feels like a big hammer. Can we restrict it to
     // only work inside generic methods?
     TypeName typeFromComment = _parseOptionalTypeNameComment();
-    return typeFromComment ?? new TypeName(typeName, typeArguments);
+    return typeFromComment ?? astFactory.typeName(typeName, typeArguments);
   }
 
   /**
@@ -7189,7 +7223,7 @@
         _reportErrorForToken(
             ParserErrorCode.NON_STRING_LITERAL_AS_URI, newToken);
         _currentToken = endToken.next;
-        return new SimpleStringLiteral(newToken, value);
+        return astFactory.simpleStringLiteral(newToken, value);
       }
     }
     return parseStringLiteral();
@@ -7212,7 +7246,7 @@
         parseVariableDeclarationListAfterType(
             commentAndMetadata, keyword, type);
     Token semicolon = _expect(TokenType.SEMICOLON);
-    return new VariableDeclarationStatement(variableList, semicolon);
+    return astFactory.variableDeclarationStatement(variableList, semicolon);
   }
 
   /**
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 4cb8cb6..724a24b 100644
--- a/pkg/analyzer/lib/src/generated/testing/ast_test_factory.dart
+++ b/pkg/analyzer/lib/src/generated/testing/ast_test_factory.dart
@@ -5,9 +5,9 @@
 library analyzer.src.generated.testing.ast_test_factory;
 
 import 'package:analyzer/dart/ast/ast.dart';
+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/src/dart/ast/ast.dart';
 import 'package:analyzer/src/generated/testing/token_factory.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart';
 
@@ -25,14 +25,14 @@
  */
 class AstTestFactory {
   static AdjacentStrings adjacentStrings(List<StringLiteral> strings) =>
-      new AdjacentStrings(strings);
+      astFactory.adjacentStrings(strings);
 
-  static Annotation annotation(Identifier name) => new Annotation(
+  static Annotation annotation(Identifier name) => astFactory.annotation(
       TokenFactory.tokenFromType(TokenType.AT), name, null, null, null);
 
   static Annotation annotation2(Identifier name,
           SimpleIdentifier constructorName, ArgumentList arguments) =>
-      new Annotation(
+      astFactory.annotation(
           TokenFactory.tokenFromType(TokenType.AT),
           name,
           constructorName == null
@@ -42,16 +42,16 @@
           arguments);
 
   static ArgumentList argumentList([List<Expression> arguments]) =>
-      new ArgumentList(TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
+      astFactory.argumentList(TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           arguments, TokenFactory.tokenFromType(TokenType.CLOSE_PAREN));
 
   static AsExpression asExpression(Expression expression, TypeName type) =>
-      new AsExpression(
+      astFactory.asExpression(
           expression, TokenFactory.tokenFromKeyword(Keyword.AS), type);
 
   static AssertStatement assertStatement(Expression condition,
           [Expression message]) =>
-      new AssertStatement(
+      astFactory.assertStatement(
           TokenFactory.tokenFromKeyword(Keyword.ASSERT),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           condition,
@@ -62,19 +62,19 @@
 
   static AssignmentExpression assignmentExpression(Expression leftHandSide,
           TokenType operator, Expression rightHandSide) =>
-      new AssignmentExpression(
+      astFactory.assignmentExpression(
           leftHandSide, TokenFactory.tokenFromType(operator), rightHandSide);
 
   static BlockFunctionBody asyncBlockFunctionBody(
           [List<Statement> statements]) =>
-      new BlockFunctionBody(
+      astFactory.blockFunctionBody(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "async"),
           null,
           block(statements));
 
   static ExpressionFunctionBody asyncExpressionFunctionBody(
           Expression expression) =>
-      new ExpressionFunctionBody(
+      astFactory.expressionFunctionBody(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "async"),
           TokenFactory.tokenFromType(TokenType.FUNCTION),
           expression,
@@ -82,50 +82,49 @@
 
   static BlockFunctionBody asyncGeneratorBlockFunctionBody(
           [List<Statement> statements]) =>
-      new BlockFunctionBody(
+      astFactory.blockFunctionBody(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "async"),
           TokenFactory.tokenFromType(TokenType.STAR),
           block(statements));
 
   static AwaitExpression awaitExpression(Expression expression) =>
-      new AwaitExpression(
+      astFactory.awaitExpression(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "await"),
           expression);
 
   static BinaryExpression binaryExpression(Expression leftOperand,
           TokenType operator, Expression rightOperand) =>
-      new BinaryExpression(
+      astFactory.binaryExpression(
           leftOperand, TokenFactory.tokenFromType(operator), rightOperand);
 
-  static Block block([List<Statement> statements]) => new Block(
+  static Block block([List<Statement> statements]) => astFactory.block(
       TokenFactory.tokenFromType(TokenType.OPEN_CURLY_BRACKET),
       statements,
       TokenFactory.tokenFromType(TokenType.CLOSE_CURLY_BRACKET));
 
   static BlockFunctionBody blockFunctionBody(Block block) =>
-      new BlockFunctionBody(null, null, block);
+      astFactory.blockFunctionBody(null, null, block);
 
   static BlockFunctionBody blockFunctionBody2([List<Statement> statements]) =>
-      new BlockFunctionBody(null, null, block(statements));
+      astFactory.blockFunctionBody(null, null, block(statements));
 
-  static BooleanLiteral booleanLiteral(bool value) => new BooleanLiteral(
+  static BooleanLiteral booleanLiteral(bool value) => astFactory.booleanLiteral(
       value
           ? TokenFactory.tokenFromKeyword(Keyword.TRUE)
           : TokenFactory.tokenFromKeyword(Keyword.FALSE),
       value);
 
-  static BreakStatement breakStatement() => new BreakStatement(
+  static BreakStatement breakStatement() => astFactory.breakStatement(
       TokenFactory.tokenFromKeyword(Keyword.BREAK),
       null,
       TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
-  static BreakStatement breakStatement2(String label) => new BreakStatement(
-      TokenFactory.tokenFromKeyword(Keyword.BREAK),
-      identifier3(label),
-      TokenFactory.tokenFromType(TokenType.SEMICOLON));
+  static BreakStatement breakStatement2(String label) =>
+      astFactory.breakStatement(TokenFactory.tokenFromKeyword(Keyword.BREAK),
+          identifier3(label), TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
   static IndexExpression cascadedIndexExpression(Expression index) =>
-      new IndexExpression.forCascade(
+      astFactory.indexExpressionForCascade(
           TokenFactory.tokenFromType(TokenType.PERIOD_PERIOD),
           TokenFactory.tokenFromType(TokenType.OPEN_SQUARE_BRACKET),
           index,
@@ -133,7 +132,7 @@
 
   static MethodInvocation cascadedMethodInvocation(String methodName,
           [List<Expression> arguments]) =>
-      new MethodInvocation(
+      astFactory.methodInvocation(
           null,
           TokenFactory.tokenFromType(TokenType.PERIOD_PERIOD),
           identifier3(methodName),
@@ -141,14 +140,14 @@
           argumentList(arguments));
 
   static PropertyAccess cascadedPropertyAccess(String propertyName) =>
-      new PropertyAccess(
+      astFactory.propertyAccess(
           null,
           TokenFactory.tokenFromType(TokenType.PERIOD_PERIOD),
           identifier3(propertyName));
 
   static CascadeExpression cascadeExpression(Expression target,
           [List<Expression> cascadeSections]) =>
-      new CascadeExpression(target, cascadeSections);
+      astFactory.cascadeExpression(target, cascadeSections);
 
   static CatchClause catchClause(String exceptionParameter,
           [List<Statement> statements]) =>
@@ -171,7 +170,7 @@
   static CatchClause catchClause5(TypeName exceptionType,
           String exceptionParameter, String stackTraceParameter,
           [List<Statement> statements]) =>
-      new CatchClause(
+      astFactory.catchClause(
           exceptionType == null
               ? null
               : TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "on"),
@@ -200,7 +199,7 @@
           WithClause withClause,
           ImplementsClause implementsClause,
           [List<ClassMember> members]) =>
-      new ClassDeclaration(
+      astFactory.classDeclaration(
           null,
           null,
           abstractKeyword == null
@@ -223,7 +222,7 @@
           TypeName superclass,
           WithClause withClause,
           ImplementsClause implementsClause) =>
-      new ClassTypeAlias(
+      astFactory.classTypeAlias(
           null,
           null,
           TokenFactory.tokenFromKeyword(Keyword.CLASS),
@@ -267,7 +266,7 @@
           String scriptTag,
           List<Directive> directives,
           List<CompilationUnitMember> declarations) =>
-      new CompilationUnit(
+      astFactory.compilationUnit(
           TokenFactory.tokenFromType(TokenType.EOF),
           scriptTag == null ? null : AstTestFactory.scriptTag(scriptTag),
           directives == null ? new List<Directive>() : directives,
@@ -278,7 +277,7 @@
 
   static ConditionalExpression conditionalExpression(Expression condition,
           Expression thenExpression, Expression elseExpression) =>
-      new ConditionalExpression(
+      astFactory.conditionalExpression(
           condition,
           TokenFactory.tokenFromType(TokenType.QUESTION),
           thenExpression,
@@ -290,7 +289,7 @@
           String name,
           FormalParameterList parameters,
           List<ConstructorInitializer> initializers) =>
-      new ConstructorDeclaration(
+      astFactory.constructorDeclaration(
           null,
           null,
           TokenFactory.tokenFromKeyword(Keyword.EXTERNAL),
@@ -317,7 +316,7 @@
           FormalParameterList parameters,
           List<ConstructorInitializer> initializers,
           FunctionBody body) =>
-      new ConstructorDeclaration(
+      astFactory.constructorDeclaration(
           null,
           null,
           null,
@@ -342,7 +341,7 @@
 
   static ConstructorFieldInitializer constructorFieldInitializer(
           bool prefixedWithThis, String fieldName, Expression expression) =>
-      new ConstructorFieldInitializer(
+      astFactory.constructorFieldInitializer(
           prefixedWithThis ? TokenFactory.tokenFromKeyword(Keyword.THIS) : null,
           prefixedWithThis
               ? TokenFactory.tokenFromType(TokenType.PERIOD)
@@ -352,13 +351,13 @@
           expression);
 
   static ConstructorName constructorName(TypeName type, String name) =>
-      new ConstructorName(
+      astFactory.constructorName(
           type,
           name == null ? null : TokenFactory.tokenFromType(TokenType.PERIOD),
           name == null ? null : identifier3(name));
 
   static ContinueStatement continueStatement([String label]) =>
-      new ContinueStatement(
+      astFactory.continueStatement(
           TokenFactory.tokenFromKeyword(Keyword.CONTINUE),
           label == null ? null : identifier3(label),
           TokenFactory.tokenFromType(TokenType.SEMICOLON));
@@ -369,7 +368,7 @@
 
   static DeclaredIdentifier declaredIdentifier2(
           Keyword keyword, TypeName type, String identifier) =>
-      new DeclaredIdentifier(
+      astFactory.declaredIdentifier(
           null,
           null,
           keyword == null ? null : TokenFactory.tokenFromKeyword(keyword),
@@ -385,11 +384,11 @@
 
   static Comment documentationComment(
       List<Token> tokens, List<CommentReference> references) {
-    return new Comment(tokens, CommentType.DOCUMENTATION, references);
+    return astFactory.documentationComment(tokens, references);
   }
 
   static DoStatement doStatement(Statement body, Expression condition) =>
-      new DoStatement(
+      astFactory.doStatement(
           TokenFactory.tokenFromKeyword(Keyword.DO),
           body,
           TokenFactory.tokenFromKeyword(Keyword.WHILE),
@@ -398,18 +397,18 @@
           TokenFactory.tokenFromType(TokenType.CLOSE_PAREN),
           TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
-  static DoubleLiteral doubleLiteral(double value) =>
-      new DoubleLiteral(TokenFactory.tokenFromString(value.toString()), value);
+  static DoubleLiteral doubleLiteral(double value) => astFactory.doubleLiteral(
+      TokenFactory.tokenFromString(value.toString()), value);
 
-  static EmptyFunctionBody emptyFunctionBody() =>
-      new EmptyFunctionBody(TokenFactory.tokenFromType(TokenType.SEMICOLON));
+  static EmptyFunctionBody emptyFunctionBody() => astFactory
+      .emptyFunctionBody(TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
-  static EmptyStatement emptyStatement() =>
-      new EmptyStatement(TokenFactory.tokenFromType(TokenType.SEMICOLON));
+  static EmptyStatement emptyStatement() => astFactory
+      .emptyStatement(TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
   static EnumDeclaration enumDeclaration(
           SimpleIdentifier name, List<EnumConstantDeclaration> constants) =>
-      new EnumDeclaration(
+      astFactory.enumDeclaration(
           null,
           null,
           TokenFactory.tokenFromKeyword(Keyword.ENUM),
@@ -424,7 +423,7 @@
     List<EnumConstantDeclaration> constants =
         new List<EnumConstantDeclaration>(count);
     for (int i = 0; i < count; i++) {
-      constants[i] = new EnumConstantDeclaration(
+      constants[i] = astFactory.enumConstantDeclaration(
           null, null, identifier3(constantNames[i]));
     }
     return enumDeclaration(identifier3(name), constants);
@@ -432,7 +431,7 @@
 
   static ExportDirective exportDirective(List<Annotation> metadata, String uri,
           [List<Combinator> combinators]) =>
-      new ExportDirective(
+      astFactory.exportDirective(
           null,
           metadata,
           TokenFactory.tokenFromKeyword(Keyword.EXPORT),
@@ -446,22 +445,22 @@
       exportDirective(null, uri, combinators);
 
   static ExpressionFunctionBody expressionFunctionBody(Expression expression) =>
-      new ExpressionFunctionBody(
+      astFactory.expressionFunctionBody(
           null,
           TokenFactory.tokenFromType(TokenType.FUNCTION),
           expression,
           TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
   static ExpressionStatement expressionStatement(Expression expression) =>
-      new ExpressionStatement(
+      astFactory.expressionStatement(
           expression, TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
-  static ExtendsClause extendsClause(TypeName type) =>
-      new ExtendsClause(TokenFactory.tokenFromKeyword(Keyword.EXTENDS), type);
+  static ExtendsClause extendsClause(TypeName type) => astFactory.extendsClause(
+      TokenFactory.tokenFromKeyword(Keyword.EXTENDS), type);
 
   static FieldDeclaration fieldDeclaration(bool isStatic, Keyword keyword,
           TypeName type, List<VariableDeclaration> variables) =>
-      new FieldDeclaration(
+      astFactory.fieldDeclaration(
           null,
           null,
           isStatic ? TokenFactory.tokenFromKeyword(Keyword.STATIC) : null,
@@ -475,7 +474,7 @@
   static FieldFormalParameter fieldFormalParameter(
           Keyword keyword, TypeName type, String identifier,
           [FormalParameterList parameterList]) =>
-      new FieldFormalParameter(
+      astFactory.fieldFormalParameter(
           null,
           null,
           keyword == null ? null : TokenFactory.tokenFromKeyword(keyword),
@@ -491,7 +490,7 @@
 
   static ForEachStatement forEachStatement(DeclaredIdentifier loopVariable,
           Expression iterator, Statement body) =>
-      new ForEachStatement.withDeclaration(
+      astFactory.forEachStatementWithDeclaration(
           null,
           TokenFactory.tokenFromKeyword(Keyword.FOR),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
@@ -503,7 +502,7 @@
 
   static ForEachStatement forEachStatement2(
           SimpleIdentifier identifier, Expression iterator, Statement body) =>
-      new ForEachStatement.withReference(
+      astFactory.forEachStatementWithReference(
           null,
           TokenFactory.tokenFromKeyword(Keyword.FOR),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
@@ -515,7 +514,7 @@
 
   static FormalParameterList formalParameterList(
           [List<FormalParameter> parameters]) =>
-      new FormalParameterList(
+      astFactory.formalParameterList(
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           parameters,
           null,
@@ -524,7 +523,7 @@
 
   static ForStatement forStatement(Expression initialization,
           Expression condition, List<Expression> updaters, Statement body) =>
-      new ForStatement(
+      astFactory.forStatement(
           TokenFactory.tokenFromKeyword(Keyword.FOR),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           null,
@@ -538,7 +537,7 @@
 
   static ForStatement forStatement2(VariableDeclarationList variableList,
           Expression condition, List<Expression> updaters, Statement body) =>
-      new ForStatement(
+      astFactory.forStatement(
           TokenFactory.tokenFromKeyword(Keyword.FOR),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           variableList,
@@ -552,7 +551,7 @@
 
   static FunctionDeclaration functionDeclaration(TypeName type, Keyword keyword,
           String name, FunctionExpression functionExpression) =>
-      new FunctionDeclaration(
+      astFactory.functionDeclaration(
           null,
           null,
           null,
@@ -566,21 +565,21 @@
           Keyword keyword,
           String name,
           FunctionExpression functionExpression) =>
-      new FunctionDeclarationStatement(
+      astFactory.functionDeclarationStatement(
           functionDeclaration(type, keyword, name, functionExpression));
 
-  static FunctionExpression functionExpression() =>
-      new FunctionExpression(null, formalParameterList(), blockFunctionBody2());
+  static FunctionExpression functionExpression() => astFactory
+      .functionExpression(null, formalParameterList(), blockFunctionBody2());
 
   static FunctionExpression functionExpression2(
           FormalParameterList parameters, FunctionBody body) =>
-      new FunctionExpression(null, parameters, body);
+      astFactory.functionExpression(null, parameters, body);
 
   static FunctionExpression functionExpression3(
           TypeParameterList typeParameters,
           FormalParameterList parameters,
           FunctionBody body) =>
-      new FunctionExpression(typeParameters, parameters, body);
+      astFactory.functionExpression(typeParameters, parameters, body);
 
   static FunctionExpressionInvocation functionExpressionInvocation(
           Expression function,
@@ -591,37 +590,39 @@
           Expression function,
           [TypeArgumentList typeArguments,
           List<Expression> arguments]) =>
-      new FunctionExpressionInvocation(
+      astFactory.functionExpressionInvocation(
           function, typeArguments, argumentList(arguments));
 
   static FunctionTypedFormalParameter functionTypedFormalParameter(
           TypeName returnType, String identifier,
           [List<FormalParameter> parameters]) =>
-      new FunctionTypedFormalParameter(null, null, returnType,
+      astFactory.functionTypedFormalParameter(null, null, returnType,
           identifier3(identifier), null, formalParameterList(parameters));
 
   static HideCombinator hideCombinator(List<SimpleIdentifier> identifiers) =>
-      new HideCombinator(TokenFactory.tokenFromString("hide"), identifiers);
+      astFactory.hideCombinator(
+          TokenFactory.tokenFromString("hide"), identifiers);
 
   static HideCombinator hideCombinator2(List<String> identifiers) =>
-      new HideCombinator(
+      astFactory.hideCombinator(
           TokenFactory.tokenFromString("hide"), identifierList(identifiers));
 
   static PrefixedIdentifier identifier(
           SimpleIdentifier prefix, SimpleIdentifier identifier) =>
-      new PrefixedIdentifier(
+      astFactory.prefixedIdentifier(
           prefix, TokenFactory.tokenFromType(TokenType.PERIOD), identifier);
 
-  static SimpleIdentifier identifier3(String lexeme) => new SimpleIdentifier(
-      TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, lexeme));
+  static SimpleIdentifier identifier3(String lexeme) =>
+      astFactory.simpleIdentifier(
+          TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, lexeme));
 
   static PrefixedIdentifier identifier4(
           String prefix, SimpleIdentifier identifier) =>
-      new PrefixedIdentifier(identifier3(prefix),
+      astFactory.prefixedIdentifier(identifier3(prefix),
           TokenFactory.tokenFromType(TokenType.PERIOD), identifier);
 
   static PrefixedIdentifier identifier5(String prefix, String identifier) =>
-      new PrefixedIdentifier(
+      astFactory.prefixedIdentifier(
           identifier3(prefix),
           TokenFactory.tokenFromType(TokenType.PERIOD),
           identifier3(identifier));
@@ -641,7 +642,7 @@
 
   static IfStatement ifStatement2(Expression condition, Statement thenStatement,
           Statement elseStatement) =>
-      new IfStatement(
+      astFactory.ifStatement(
           TokenFactory.tokenFromKeyword(Keyword.IF),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           condition,
@@ -653,13 +654,13 @@
           elseStatement);
 
   static ImplementsClause implementsClause(List<TypeName> types) =>
-      new ImplementsClause(
+      astFactory.implementsClause(
           TokenFactory.tokenFromKeyword(Keyword.IMPLEMENTS), types);
 
   static ImportDirective importDirective(
           List<Annotation> metadata, String uri, bool isDeferred, String prefix,
           [List<Combinator> combinators]) =>
-      new ImportDirective(
+      astFactory.importDirective(
           null,
           metadata,
           TokenFactory.tokenFromKeyword(Keyword.IMPORT),
@@ -681,7 +682,7 @@
       importDirective(null, uri, false, prefix, combinators);
 
   static IndexExpression indexExpression(Expression array, Expression index) =>
-      new IndexExpression.forTarget(
+      astFactory.indexExpressionForTarget(
           array,
           TokenFactory.tokenFromType(TokenType.OPEN_SQUARE_BRACKET),
           index,
@@ -690,7 +691,7 @@
   static InstanceCreationExpression instanceCreationExpression(
           Keyword keyword, ConstructorName name,
           [List<Expression> arguments]) =>
-      new InstanceCreationExpression(
+      astFactory.instanceCreationExpression(
           keyword == null ? null : TokenFactory.tokenFromKeyword(keyword),
           name,
           argumentList(arguments));
@@ -705,7 +706,7 @@
           [List<Expression> arguments]) =>
       instanceCreationExpression(
           keyword,
-          new ConstructorName(
+          astFactory.constructorName(
               type,
               identifier == null
                   ? null
@@ -713,44 +714,48 @@
               identifier == null ? null : identifier3(identifier)),
           arguments);
 
-  static IntegerLiteral integer(int value) => new IntegerLiteral(
+  static IntegerLiteral integer(int value) => astFactory.integerLiteral(
       TokenFactory.tokenFromTypeAndString(TokenType.INT, value.toString()),
       value);
 
   static InterpolationExpression interpolationExpression(
           Expression expression) =>
-      new InterpolationExpression(
+      astFactory.interpolationExpression(
           TokenFactory.tokenFromType(TokenType.STRING_INTERPOLATION_EXPRESSION),
           expression,
           TokenFactory.tokenFromType(TokenType.CLOSE_CURLY_BRACKET));
 
   static InterpolationExpression interpolationExpression2(String identifier) =>
-      new InterpolationExpression(
+      astFactory.interpolationExpression(
           TokenFactory.tokenFromType(TokenType.STRING_INTERPOLATION_IDENTIFIER),
           identifier3(identifier),
           null);
 
   static InterpolationString interpolationString(
           String contents, String value) =>
-      new InterpolationString(TokenFactory.tokenFromString(contents), value);
+      astFactory.interpolationString(
+          TokenFactory.tokenFromString(contents), value);
 
   static IsExpression isExpression(
           Expression expression, bool negated, TypeName type) =>
-      new IsExpression(expression, TokenFactory.tokenFromKeyword(Keyword.IS),
-          negated ? TokenFactory.tokenFromType(TokenType.BANG) : null, type);
+      astFactory.isExpression(
+          expression,
+          TokenFactory.tokenFromKeyword(Keyword.IS),
+          negated ? TokenFactory.tokenFromType(TokenType.BANG) : null,
+          type);
 
   static Label label(SimpleIdentifier label) =>
-      new Label(label, TokenFactory.tokenFromType(TokenType.COLON));
+      astFactory.label(label, TokenFactory.tokenFromType(TokenType.COLON));
 
   static Label label2(String label) => AstTestFactory.label(identifier3(label));
 
   static LabeledStatement labeledStatement(
           List<Label> labels, Statement statement) =>
-      new LabeledStatement(labels, statement);
+      astFactory.labeledStatement(labels, statement);
 
   static LibraryDirective libraryDirective(
           List<Annotation> metadata, LibraryIdentifier libraryName) =>
-      new LibraryDirective(
+      astFactory.libraryDirective(
           null,
           metadata,
           TokenFactory.tokenFromKeyword(Keyword.LIBRARY),
@@ -763,10 +768,10 @@
 
   static LibraryIdentifier libraryIdentifier(
           List<SimpleIdentifier> components) =>
-      new LibraryIdentifier(components);
+      astFactory.libraryIdentifier(components);
 
   static LibraryIdentifier libraryIdentifier2(List<String> components) {
-    return new LibraryIdentifier(identifierList(components));
+    return astFactory.libraryIdentifier(identifierList(components));
   }
 
   static List list(List<Object> elements) {
@@ -779,7 +784,7 @@
   static ListLiteral listLiteral2(
           Keyword keyword, TypeArgumentList typeArguments,
           [List<Expression> elements]) =>
-      new ListLiteral(
+      astFactory.listLiteral(
           keyword == null ? null : TokenFactory.tokenFromKeyword(keyword),
           typeArguments,
           TokenFactory.tokenFromType(TokenType.OPEN_SQUARE_BRACKET),
@@ -788,7 +793,7 @@
 
   static MapLiteral mapLiteral(Keyword keyword, TypeArgumentList typeArguments,
           [List<MapLiteralEntry> entries]) =>
-      new MapLiteral(
+      astFactory.mapLiteral(
           keyword == null ? null : TokenFactory.tokenFromKeyword(keyword),
           typeArguments,
           TokenFactory.tokenFromType(TokenType.OPEN_CURLY_BRACKET),
@@ -799,11 +804,11 @@
       mapLiteral(null, null, entries);
 
   static MapLiteralEntry mapLiteralEntry(String key, Expression value) =>
-      new MapLiteralEntry(
+      astFactory.mapLiteralEntry(
           string2(key), TokenFactory.tokenFromType(TokenType.COLON), value);
 
   static MapLiteralEntry mapLiteralEntry2(Expression key, Expression value) =>
-      new MapLiteralEntry(
+      astFactory.mapLiteralEntry(
           key, TokenFactory.tokenFromType(TokenType.COLON), value);
 
   static MethodDeclaration methodDeclaration(
@@ -813,7 +818,7 @@
           Keyword operator,
           SimpleIdentifier name,
           FormalParameterList parameters) =>
-      new MethodDeclaration(
+      astFactory.methodDeclaration(
           null,
           null,
           TokenFactory.tokenFromKeyword(Keyword.EXTERNAL),
@@ -834,7 +839,7 @@
           SimpleIdentifier name,
           FormalParameterList parameters,
           FunctionBody body) =>
-      new MethodDeclaration(
+      astFactory.methodDeclaration(
           null,
           null,
           null,
@@ -856,7 +861,7 @@
           TypeParameterList typeParameters,
           FormalParameterList parameters,
           FunctionBody body) =>
-      new MethodDeclaration(
+      astFactory.methodDeclaration(
           null,
           null,
           null,
@@ -878,7 +883,7 @@
           String name,
           FormalParameterList parameters,
           FunctionBody body}) =>
-      new MethodDeclaration(
+      astFactory.methodDeclaration(
           null,
           null,
           external ? TokenFactory.tokenFromKeyword(Keyword.EXTERNAL) : null,
@@ -894,7 +899,7 @@
   static MethodInvocation methodInvocation(Expression target, String methodName,
           [List<Expression> arguments,
           TokenType operator = TokenType.PERIOD]) =>
-      new MethodInvocation(
+      astFactory.methodInvocation(
           target,
           target == null ? null : TokenFactory.tokenFromType(operator),
           identifier3(methodName),
@@ -909,7 +914,7 @@
           Expression target, String methodName, TypeArgumentList typeArguments,
           [List<Expression> arguments,
           TokenType operator = TokenType.PERIOD]) =>
-      new MethodInvocation(
+      astFactory.methodInvocation(
           target,
           target == null ? null : TokenFactory.tokenFromType(operator),
           identifier3(methodName),
@@ -917,7 +922,7 @@
           argumentList(arguments));
 
   static NamedExpression namedExpression(Label label, Expression expression) =>
-      new NamedExpression(label, expression);
+      astFactory.namedExpression(label, expression);
 
   static NamedExpression namedExpression2(
           String label, Expression expression) =>
@@ -925,7 +930,7 @@
 
   static DefaultFormalParameter namedFormalParameter(
           NormalFormalParameter parameter, Expression expression) =>
-      new DefaultFormalParameter(
+      astFactory.defaultFormalParameter(
           parameter,
           ParameterKind.NAMED,
           expression == null
@@ -933,27 +938,28 @@
               : TokenFactory.tokenFromType(TokenType.COLON),
           expression);
 
-  static NativeClause nativeClause(String nativeCode) => new NativeClause(
-      TokenFactory.tokenFromString("native"), string2(nativeCode));
+  static NativeClause nativeClause(String nativeCode) =>
+      astFactory.nativeClause(
+          TokenFactory.tokenFromString("native"), string2(nativeCode));
 
   static NativeFunctionBody nativeFunctionBody(String nativeMethodName) =>
-      new NativeFunctionBody(
+      astFactory.nativeFunctionBody(
           TokenFactory.tokenFromString("native"),
           string2(nativeMethodName),
           TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
   static NullLiteral nullLiteral() =>
-      new NullLiteral(TokenFactory.tokenFromKeyword(Keyword.NULL));
+      astFactory.nullLiteral(TokenFactory.tokenFromKeyword(Keyword.NULL));
 
   static ParenthesizedExpression parenthesizedExpression(
           Expression expression) =>
-      new ParenthesizedExpression(
+      astFactory.parenthesizedExpression(
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           expression,
           TokenFactory.tokenFromType(TokenType.CLOSE_PAREN));
 
   static PartDirective partDirective(List<Annotation> metadata, String url) =>
-      new PartDirective(
+      astFactory.partDirective(
           null,
           metadata,
           TokenFactory.tokenFromKeyword(Keyword.PART),
@@ -968,7 +974,7 @@
 
   static PartOfDirective partOfDirective2(
           List<Annotation> metadata, LibraryIdentifier libraryName) =>
-      new PartOfDirective(
+      astFactory.partOfDirective(
           null,
           metadata,
           TokenFactory.tokenFromKeyword(Keyword.PART),
@@ -979,7 +985,7 @@
 
   static DefaultFormalParameter positionalFormalParameter(
           NormalFormalParameter parameter, Expression expression) =>
-      new DefaultFormalParameter(
+      astFactory.defaultFormalParameter(
           parameter,
           ParameterKind.POSITIONAL,
           expression == null ? null : TokenFactory.tokenFromType(TokenType.EQ),
@@ -987,20 +993,22 @@
 
   static PostfixExpression postfixExpression(
           Expression expression, TokenType operator) =>
-      new PostfixExpression(expression, TokenFactory.tokenFromType(operator));
+      astFactory.postfixExpression(
+          expression, TokenFactory.tokenFromType(operator));
 
   static PrefixExpression prefixExpression(
           TokenType operator, Expression expression) =>
-      new PrefixExpression(TokenFactory.tokenFromType(operator), expression);
+      astFactory.prefixExpression(
+          TokenFactory.tokenFromType(operator), expression);
 
   static PropertyAccess propertyAccess(
           Expression target, SimpleIdentifier propertyName) =>
-      new PropertyAccess(
+      astFactory.propertyAccess(
           target, TokenFactory.tokenFromType(TokenType.PERIOD), propertyName);
 
   static PropertyAccess propertyAccess2(Expression target, String propertyName,
           [TokenType operator = TokenType.PERIOD]) =>
-      new PropertyAccess(target, TokenFactory.tokenFromType(operator),
+      astFactory.propertyAccess(target, TokenFactory.tokenFromType(operator),
           identifier3(propertyName));
 
   static RedirectingConstructorInvocation redirectingConstructorInvocation(
@@ -1010,7 +1018,7 @@
   static RedirectingConstructorInvocation redirectingConstructorInvocation2(
           String constructorName,
           [List<Expression> arguments]) =>
-      new RedirectingConstructorInvocation(
+      astFactory.redirectingConstructorInvocation(
           TokenFactory.tokenFromKeyword(Keyword.THIS),
           constructorName == null
               ? null
@@ -1018,23 +1026,24 @@
           constructorName == null ? null : identifier3(constructorName),
           argumentList(arguments));
 
-  static RethrowExpression rethrowExpression() =>
-      new RethrowExpression(TokenFactory.tokenFromKeyword(Keyword.RETHROW));
+  static RethrowExpression rethrowExpression() => astFactory
+      .rethrowExpression(TokenFactory.tokenFromKeyword(Keyword.RETHROW));
 
   static ReturnStatement returnStatement() => returnStatement2(null);
 
   static ReturnStatement returnStatement2(Expression expression) =>
-      new ReturnStatement(TokenFactory.tokenFromKeyword(Keyword.RETURN),
+      astFactory.returnStatement(TokenFactory.tokenFromKeyword(Keyword.RETURN),
           expression, TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
   static ScriptTag scriptTag(String scriptTag) =>
-      new ScriptTag(TokenFactory.tokenFromString(scriptTag));
+      astFactory.scriptTag(TokenFactory.tokenFromString(scriptTag));
 
   static ShowCombinator showCombinator(List<SimpleIdentifier> identifiers) =>
-      new ShowCombinator(TokenFactory.tokenFromString("show"), identifiers);
+      astFactory.showCombinator(
+          TokenFactory.tokenFromString("show"), identifiers);
 
   static ShowCombinator showCombinator2(List<String> identifiers) =>
-      new ShowCombinator(
+      astFactory.showCombinator(
           TokenFactory.tokenFromString("show"), identifierList(identifiers));
 
   static SimpleFormalParameter simpleFormalParameter(
@@ -1043,7 +1052,7 @@
 
   static SimpleFormalParameter simpleFormalParameter2(
           Keyword keyword, TypeName type, String parameterName) =>
-      new SimpleFormalParameter(
+      astFactory.simpleFormalParameter(
           null,
           null,
           keyword == null ? null : TokenFactory.tokenFromKeyword(keyword),
@@ -1058,10 +1067,10 @@
       simpleFormalParameter2(null, type, parameterName);
 
   static StringInterpolation string([List<InterpolationElement> elements]) =>
-      new StringInterpolation(elements);
+      astFactory.stringInterpolation(elements);
 
-  static SimpleStringLiteral string2(String content) => new SimpleStringLiteral(
-      TokenFactory.tokenFromString("'$content'"), content);
+  static SimpleStringLiteral string2(String content) => astFactory
+      .simpleStringLiteral(TokenFactory.tokenFromString("'$content'"), content);
 
   static SuperConstructorInvocation superConstructorInvocation(
           [List<Expression> arguments]) =>
@@ -1069,14 +1078,14 @@
 
   static SuperConstructorInvocation superConstructorInvocation2(String name,
           [List<Expression> arguments]) =>
-      new SuperConstructorInvocation(
+      astFactory.superConstructorInvocation(
           TokenFactory.tokenFromKeyword(Keyword.SUPER),
           name == null ? null : TokenFactory.tokenFromType(TokenType.PERIOD),
           name == null ? null : identifier3(name),
           argumentList(arguments));
 
   static SuperExpression superExpression() =>
-      new SuperExpression(TokenFactory.tokenFromKeyword(Keyword.SUPER));
+      astFactory.superExpression(TokenFactory.tokenFromKeyword(Keyword.SUPER));
 
   static SwitchCase switchCase(
           Expression expression, List<Statement> statements) =>
@@ -1084,20 +1093,23 @@
 
   static SwitchCase switchCase2(List<Label> labels, Expression expression,
           List<Statement> statements) =>
-      new SwitchCase(labels, TokenFactory.tokenFromKeyword(Keyword.CASE),
+      astFactory.switchCase(labels, TokenFactory.tokenFromKeyword(Keyword.CASE),
           expression, TokenFactory.tokenFromType(TokenType.COLON), statements);
 
   static SwitchDefault switchDefault(
           List<Label> labels, List<Statement> statements) =>
-      new SwitchDefault(labels, TokenFactory.tokenFromKeyword(Keyword.DEFAULT),
-          TokenFactory.tokenFromType(TokenType.COLON), statements);
+      astFactory.switchDefault(
+          labels,
+          TokenFactory.tokenFromKeyword(Keyword.DEFAULT),
+          TokenFactory.tokenFromType(TokenType.COLON),
+          statements);
 
   static SwitchDefault switchDefault2(List<Statement> statements) =>
       switchDefault(new List<Label>(), statements);
 
   static SwitchStatement switchStatement(
           Expression expression, List<SwitchMember> members) =>
-      new SwitchStatement(
+      astFactory.switchStatement(
           TokenFactory.tokenFromKeyword(Keyword.SWITCH),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           expression,
@@ -1112,38 +1124,38 @@
       identifierList.add(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, component));
     }
-    return new SymbolLiteral(
+    return astFactory.symbolLiteral(
         TokenFactory.tokenFromType(TokenType.HASH), identifierList);
   }
 
   static BlockFunctionBody syncBlockFunctionBody(
           [List<Statement> statements]) =>
-      new BlockFunctionBody(
+      astFactory.blockFunctionBody(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "sync"),
           null,
           block(statements));
 
   static BlockFunctionBody syncGeneratorBlockFunctionBody(
           [List<Statement> statements]) =>
-      new BlockFunctionBody(
+      astFactory.blockFunctionBody(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "sync"),
           TokenFactory.tokenFromType(TokenType.STAR),
           block(statements));
 
   static ThisExpression thisExpression() =>
-      new ThisExpression(TokenFactory.tokenFromKeyword(Keyword.THIS));
+      astFactory.thisExpression(TokenFactory.tokenFromKeyword(Keyword.THIS));
 
   static ThrowExpression throwExpression() => throwExpression2(null);
 
   static ThrowExpression throwExpression2(Expression expression) =>
-      new ThrowExpression(
+      astFactory.throwExpression(
           TokenFactory.tokenFromKeyword(Keyword.THROW), expression);
 
   static TopLevelVariableDeclaration topLevelVariableDeclaration(
           Keyword keyword,
           TypeName type,
           List<VariableDeclaration> variables) =>
-      new TopLevelVariableDeclaration(
+      astFactory.topLevelVariableDeclaration(
           null,
           null,
           variableDeclarationList(keyword, type, variables),
@@ -1151,7 +1163,7 @@
 
   static TopLevelVariableDeclaration topLevelVariableDeclaration2(
           Keyword keyword, List<VariableDeclaration> variables) =>
-      new TopLevelVariableDeclaration(
+      astFactory.topLevelVariableDeclaration(
           null,
           null,
           variableDeclarationList(keyword, null, variables),
@@ -1166,7 +1178,7 @@
 
   static TryStatement tryStatement3(
           Block body, List<CatchClause> catchClauses, Block finallyClause) =>
-      new TryStatement(
+      astFactory.tryStatement(
           TokenFactory.tokenFromKeyword(Keyword.TRY),
           body,
           catchClauses,
@@ -1177,7 +1189,7 @@
 
   static FunctionTypeAlias typeAlias(TypeName returnType, String name,
           TypeParameterList typeParameters, FormalParameterList parameters) =>
-      new FunctionTypeAlias(
+      astFactory.functionTypeAlias(
           null,
           null,
           TokenFactory.tokenFromKeyword(Keyword.TYPEDEF),
@@ -1191,7 +1203,7 @@
     if (typeNames == null || typeNames.length == 0) {
       return null;
     }
-    return new TypeArgumentList(TokenFactory.tokenFromType(TokenType.LT),
+    return astFactory.typeArgumentList(TokenFactory.tokenFromType(TokenType.LT),
         typeNames, TokenFactory.tokenFromType(TokenType.GT));
   }
 
@@ -1211,16 +1223,16 @@
   }
 
   static TypeName typeName3(Identifier name, [List<TypeName> arguments]) =>
-      new TypeName(name, typeArgumentList(arguments));
+      astFactory.typeName(name, typeArgumentList(arguments));
 
   static TypeName typeName4(String name, [List<TypeName> arguments]) =>
-      new TypeName(identifier3(name), typeArgumentList(arguments));
+      astFactory.typeName(identifier3(name), typeArgumentList(arguments));
 
   static TypeParameter typeParameter(String name) =>
-      new TypeParameter(null, null, identifier3(name), null, null);
+      astFactory.typeParameter(null, null, identifier3(name), null, null);
 
   static TypeParameter typeParameter2(String name, TypeName bound) =>
-      new TypeParameter(null, null, identifier3(name),
+      astFactory.typeParameter(null, null, identifier3(name),
           TokenFactory.tokenFromKeyword(Keyword.EXTENDS), bound);
 
   static TypeParameterList typeParameterList([List<String> typeNames]) {
@@ -1231,21 +1243,23 @@
         typeParameters.add(typeParameter(typeName));
       }
     }
-    return new TypeParameterList(TokenFactory.tokenFromType(TokenType.LT),
-        typeParameters, TokenFactory.tokenFromType(TokenType.GT));
+    return astFactory.typeParameterList(
+        TokenFactory.tokenFromType(TokenType.LT),
+        typeParameters,
+        TokenFactory.tokenFromType(TokenType.GT));
   }
 
   static VariableDeclaration variableDeclaration(String name) =>
-      new VariableDeclaration(identifier3(name), null, null);
+      astFactory.variableDeclaration(identifier3(name), null, null);
 
   static VariableDeclaration variableDeclaration2(
           String name, Expression initializer) =>
-      new VariableDeclaration(identifier3(name),
+      astFactory.variableDeclaration(identifier3(name),
           TokenFactory.tokenFromType(TokenType.EQ), initializer);
 
   static VariableDeclarationList variableDeclarationList(Keyword keyword,
           TypeName type, List<VariableDeclaration> variables) =>
-      new VariableDeclarationList(
+      astFactory.variableDeclarationList(
           null,
           null,
           keyword == null ? null : TokenFactory.tokenFromKeyword(keyword),
@@ -1260,7 +1274,7 @@
           Keyword keyword,
           TypeName type,
           List<VariableDeclaration> variables) =>
-      new VariableDeclarationStatement(
+      astFactory.variableDeclarationStatement(
           variableDeclarationList(keyword, type, variables),
           TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
@@ -1269,7 +1283,7 @@
       variableDeclarationStatement(keyword, null, variables);
 
   static WhileStatement whileStatement(Expression condition, Statement body) =>
-      new WhileStatement(
+      astFactory.whileStatement(
           TokenFactory.tokenFromKeyword(Keyword.WHILE),
           TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
           condition,
@@ -1277,17 +1291,17 @@
           body);
 
   static WithClause withClause(List<TypeName> types) =>
-      new WithClause(TokenFactory.tokenFromKeyword(Keyword.WITH), types);
+      astFactory.withClause(TokenFactory.tokenFromKeyword(Keyword.WITH), types);
 
   static YieldStatement yieldEachStatement(Expression expression) =>
-      new YieldStatement(
+      astFactory.yieldStatement(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "yield"),
           TokenFactory.tokenFromType(TokenType.STAR),
           expression,
           TokenFactory.tokenFromType(TokenType.SEMICOLON));
 
   static YieldStatement yieldStatement(Expression expression) =>
-      new YieldStatement(
+      astFactory.yieldStatement(
           TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "yield"),
           null,
           expression,
diff --git a/pkg/analyzer/lib/src/services/lint.dart b/pkg/analyzer/lib/src/services/lint.dart
index 097a8df..af6a3ee 100644
--- a/pkg/analyzer/lib/src/services/lint.dart
+++ b/pkg/analyzer/lib/src/services/lint.dart
@@ -8,6 +8,7 @@
 
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/error/listener.dart';
+import 'package:analyzer/src/dart/error/lint_codes.dart';
 import 'package:analyzer/src/generated/engine.dart';
 
 /// Shared lint registry.
@@ -32,6 +33,11 @@
   /// NOTE: this is set by the framework before visit begins.
   ErrorReporter reporter;
 
+  /**
+   * Return the lint code associated with this linter.
+   */
+  LintCode get lintCode => null;
+
   /// Linter name.
   String get name;
 
diff --git a/pkg/analyzer/lib/src/summary/format.fbs b/pkg/analyzer/lib/src/summary/format.fbs
index de75fea..d918405 100644
--- a/pkg/analyzer/lib/src/summary/format.fbs
+++ b/pkg/analyzer/lib/src/summary/format.fbs
@@ -771,7 +771,38 @@
    * Pop the top value from the stack.  Treat it as a Future and await its
    * completion.  Then push the awaited value onto the stack.
    */
-  await
+  await,
+
+  /**
+   * Push an abstract value onto the stack. Abstract values mark the presence of
+   * a value, but whose details are not included.
+   *
+   * This is not used by the summary generators today, but it will be used to
+   * experiment with prunning the initializer expression tree, so only
+   * information that is necessary gets included in the output summary file.
+   */
+  pushUntypedAbstract,
+
+  /**
+   * Get the next type reference from [UnlinkedExpr.references] and push an
+   * abstract value onto the stack that has that type.
+   *
+   * Like [pushUntypedAbstract], this is also not used by the summary generators
+   * today. The plan is to experiment with prunning the initializer expression
+   * tree, and include just enough type information to perform strong-mode type
+   * inference, but not all the details of how this type was obtained.
+   */
+  pushTypedAbstract,
+
+  /**
+   * Push an error onto the stack.
+   *
+   * Like [pushUntypedAbstract], this is not used by summary generators today.
+   * This will be used to experiment with prunning the const expression tree. If
+   * a constant has an error, we can omit the subexpression containing the error
+   * and only include a marker that an error was detected.
+   */
+  pushError
 }
 
 /**
diff --git a/pkg/analyzer/lib/src/summary/idl.dart b/pkg/analyzer/lib/src/summary/idl.dart
index 9c07aff..6eb2dcc 100644
--- a/pkg/analyzer/lib/src/summary/idl.dart
+++ b/pkg/analyzer/lib/src/summary/idl.dart
@@ -2347,6 +2347,37 @@
    * completion.  Then push the awaited value onto the stack.
    */
   await,
+
+  /**
+   * Push an abstract value onto the stack. Abstract values mark the presence of
+   * a value, but whose details are not included.
+   *
+   * This is not used by the summary generators today, but it will be used to
+   * experiment with prunning the initializer expression tree, so only
+   * information that is necessary gets included in the output summary file.
+   */
+  pushUntypedAbstract,
+
+  /**
+   * Get the next type reference from [UnlinkedExpr.references] and push an
+   * abstract value onto the stack that has that type.
+   *
+   * Like [pushUntypedAbstract], this is also not used by the summary generators
+   * today. The plan is to experiment with prunning the initializer expression
+   * tree, and include just enough type information to perform strong-mode type
+   * inference, but not all the details of how this type was obtained.
+   */
+  pushTypedAbstract,
+
+  /**
+   * Push an error onto the stack.
+   *
+   * Like [pushUntypedAbstract], this is not used by summary generators today.
+   * This will be used to experiment with prunning the const expression tree. If
+   * a constant has an error, we can omit the subexpression containing the error
+   * and only include a marker that an error was detected.
+   */
+  pushError,
 }
 
 /**
diff --git a/pkg/analyzer/lib/src/summary/link.dart b/pkg/analyzer/lib/src/summary/link.dart
index ec0806e..1e375c9 100644
--- a/pkg/analyzer/lib/src/summary/link.dart
+++ b/pkg/analyzer/lib/src/summary/link.dart
@@ -72,6 +72,7 @@
 import 'package:analyzer/src/summary/idl.dart';
 import 'package:analyzer/src/summary/prelink.dart';
 import 'package:analyzer/src/task/strong_mode.dart';
+import 'package:front_end/src/dependency_walker.dart';
 
 bool isIncrementOrDecrement(UnlinkedExprAssignOperator operator) {
   switch (operator) {
@@ -1752,132 +1753,6 @@
 }
 
 /**
- * An instance of [DependencyWalker] contains the core algorithms for
- * walking a dependency graph and evaluating nodes in a safe order.
- */
-abstract class DependencyWalker<NodeType extends Node<NodeType>> {
-  /**
-   * Called by [walk] to evaluate a single non-cyclical node, after
-   * all that node's dependencies have been evaluated.
-   */
-  void evaluate(NodeType v);
-
-  /**
-   * Called by [walk] to evaluate a strongly connected component
-   * containing one or more nodes.  All dependencies of the strongly
-   * connected component have been evaluated.
-   */
-  void evaluateScc(List<NodeType> scc);
-
-  /**
-   * Walk the dependency graph starting at [startingPoint], finding
-   * strongly connected components and evaluating them in a safe order
-   * by calling [evaluate] and [evaluateScc].
-   *
-   * This is an implementation of Tarjan's strongly connected
-   * components algorithm
-   * (https://en.wikipedia.org/wiki/Tarjan%27s_strongly_connected_components_algorithm).
-   */
-  void walk(NodeType startingPoint) {
-    // TODO(paulberry): consider rewriting in a non-recursive way so
-    // that long dependency chains don't cause stack overflow.
-
-    // TODO(paulberry): in the event that an exception occurs during
-    // the walk, restore the state of the [Node] data structures so
-    // that further evaluation will be safe.
-
-    // The index which will be assigned to the next node that is
-    // freshly visited.
-    int index = 1;
-
-    // Stack of nodes which have been seen so far and whose strongly
-    // connected component is still being determined.  Nodes are only
-    // popped off the stack when they are evaluated, so sometimes the
-    // stack contains nodes that were visited after the current node.
-    List<NodeType> stack = <NodeType>[];
-
-    void strongConnect(NodeType node) {
-      bool hasTrivialCycle = false;
-
-      // Assign the current node an index and add it to the stack.  We
-      // haven't seen any of its dependencies yet, so set its lowLink
-      // to its index, indicating that so far it is the only node in
-      // its strongly connected component.
-      node.index = node.lowLink = index++;
-      stack.add(node);
-
-      // Consider the node's dependencies one at a time.
-      for (NodeType dependency in node.dependencies) {
-        // If the dependency has already been evaluated, it can't be
-        // part of this node's strongly connected component, so we can
-        // skip it.
-        if (dependency.isEvaluated) {
-          continue;
-        }
-        if (identical(node, dependency)) {
-          // If a node includes itself as a dependency, there is no need to
-          // explore the dependency further.
-          hasTrivialCycle = true;
-        } else if (dependency.index == 0) {
-          // The dependency hasn't been seen yet, so recurse on it.
-          strongConnect(dependency);
-          // If the dependency's lowLink refers to a node that was
-          // visited before the current node, that means that the
-          // current node, the dependency, and the node referred to by
-          // the dependency's lowLink are all part of the same
-          // strongly connected component, so we need to update the
-          // current node's lowLink accordingly.
-          if (dependency.lowLink < node.lowLink) {
-            node.lowLink = dependency.lowLink;
-          }
-        } else {
-          // The dependency has already been seen, so it is part of
-          // the current node's strongly connected component.  If it
-          // was visited earlier than the current node's lowLink, then
-          // it is a new addition to the current node's strongly
-          // connected component, so we need to update the current
-          // node's lowLink accordingly.
-          if (dependency.index < node.lowLink) {
-            node.lowLink = dependency.index;
-          }
-        }
-      }
-
-      // If the current node's lowLink is the same as its index, then
-      // we have finished visiting a strongly connected component, so
-      // pop the stack and evaluate it before moving on.
-      if (node.lowLink == node.index) {
-        // The strongly connected component has only one node.  If there is a
-        // cycle, it's a trivial one.
-        if (identical(stack.last, node)) {
-          stack.removeLast();
-          if (hasTrivialCycle) {
-            evaluateScc(<NodeType>[node]);
-          } else {
-            evaluate(node);
-          }
-        } else {
-          // There are multiple nodes in the strongly connected
-          // component.
-          List<NodeType> scc = <NodeType>[];
-          while (true) {
-            NodeType otherNode = stack.removeLast();
-            scc.add(otherNode);
-            if (identical(otherNode, node)) {
-              break;
-            }
-          }
-          evaluateScc(scc);
-        }
-      }
-    }
-
-    // Kick off the algorithm starting with the starting point.
-    strongConnect(startingPoint);
-  }
-}
-
-/**
  * Base class for executable elements resynthesized from a summary during
  * linking.
  */
@@ -3856,45 +3731,6 @@
 }
 
 /**
- * Instances of [Node] represent nodes in a dependency graph.  The
- * type parameter, [NodeType], is the derived type (this affords some
- * extra type safety by making it difficult to accidentally construct
- * bridges between unrelated dependency graphs).
- */
-abstract class Node<NodeType> {
-  /**
-   * Index used by Tarjan's strongly connected components algorithm.
-   * Zero means the node has not been visited yet; a nonzero value
-   * counts the order in which the node was visited.
-   */
-  int index = 0;
-
-  /**
-   * Low link used by Tarjan's strongly connected components
-   * algorithm.  This represents the smallest [index] of all the nodes
-   * in the strongly connected component to which this node belongs.
-   */
-  int lowLink = 0;
-
-  List<NodeType> _dependencies;
-
-  /**
-   * Retrieve the dependencies of this node.
-   */
-  List<NodeType> get dependencies => _dependencies ??= computeDependencies();
-
-  /**
-   * Indicates whether this node has been evaluated yet.
-   */
-  bool get isEvaluated;
-
-  /**
-   * Compute the dependencies of this node.
-   */
-  List<NodeType> computeDependencies();
-}
-
-/**
  * Element used for references that result from trying to access a non-static
  * member of an element that is not a container (e.g. accessing the "length"
  * property of a constant).
diff --git a/pkg/analyzer/lib/src/summary/package_bundle_reader.dart b/pkg/analyzer/lib/src/summary/package_bundle_reader.dart
index d178797..76dc164 100644
--- a/pkg/analyzer/lib/src/summary/package_bundle_reader.dart
+++ b/pkg/analyzer/lib/src/summary/package_bundle_reader.dart
@@ -389,15 +389,29 @@
     for (int i = 0; i < bundle.unlinkedUnitUris.length; i++) {
       String uri = bundle.unlinkedUnitUris[i];
       uriToSummaryPath[uri] = path;
-      unlinkedMap[uri] = bundle.unlinkedUnits[i];
+      addUnlinkedUnit(uri, bundle.unlinkedUnits[i]);
     }
     for (int i = 0; i < bundle.linkedLibraryUris.length; i++) {
       String uri = bundle.linkedLibraryUris[i];
-      linkedMap[uri] = bundle.linkedLibraries[i];
+      addLinkedLibrary(uri, bundle.linkedLibraries[i]);
     }
   }
 
   /**
+   * Add the given [linkedLibrary] with the given [uri].
+   */
+  void addLinkedLibrary(String uri, LinkedLibrary linkedLibrary) {
+    linkedMap[uri] = linkedLibrary;
+  }
+
+  /**
+   * Add the given [unlinkedUnit] with the given [uri].
+   */
+  void addUnlinkedUnit(String uri, UnlinkedUnit unlinkedUnit) {
+    unlinkedMap[uri] = unlinkedUnit;
+  }
+
+  /**
    * Return a list of absolute URIs of the libraries that contain the unit with
    * the given [unitUriString], or `null` if no such library is in the store.
    */
diff --git a/pkg/analyzer/lib/src/summary/resynthesize.dart b/pkg/analyzer/lib/src/summary/resynthesize.dart
index bee1e9e..88dfc68 100644
--- a/pkg/analyzer/lib/src/summary/resynthesize.dart
+++ b/pkg/analyzer/lib/src/summary/resynthesize.dart
@@ -7,6 +7,7 @@
 import 'dart:collection';
 
 import 'package:analyzer/dart/ast/ast.dart';
+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/type.dart';
@@ -217,7 +218,8 @@
         libraryElement.definingCompilationUnit = unitElement;
         unitElement.source = librarySource;
         unitElement.librarySource = librarySource;
-        return libraryElement..isSynthetic = true;
+        libraryElement.createLoadLibraryFunction(typeProvider);
+        return libraryElement;
       }
       UnlinkedUnit unlinkedSummary = _getUnlinkedSummaryOrNull(uri);
       if (unlinkedSummary == null) {
@@ -515,6 +517,9 @@
         case UnlinkedExprOperation.typeCheck:
         case UnlinkedExprOperation.throwException:
         case UnlinkedExprOperation.pushLocalFunctionReference:
+        case UnlinkedExprOperation.pushError:
+        case UnlinkedExprOperation.pushTypedAbstract:
+        case UnlinkedExprOperation.pushUntypedAbstract:
           throw new UnimplementedError(
               'Unexpected $operation in a constant expression.');
       }
@@ -588,9 +593,9 @@
 
   InterpolationElement _newInterpolationElement(Expression expr) {
     if (expr is SimpleStringLiteral) {
-      return new InterpolationString(expr.literal, expr.value);
+      return astFactory.interpolationString(expr.literal, expr.value);
     } else {
-      return new InterpolationExpression(
+      return astFactory.interpolationExpression(
           TokenFactory.tokenFromType(TokenType.STRING_INTERPOLATION_EXPRESSION),
           expr,
           TokenFactory.tokenFromType(TokenType.CLOSE_CURLY_BRACKET));
@@ -714,7 +719,7 @@
       typeArguments = AstTestFactory.typeArgumentList(typeNames);
     }
     if (node is SimpleIdentifier) {
-      _push(new MethodInvocation(
+      _push(astFactory.methodInvocation(
           null,
           TokenFactory.tokenFromType(TokenType.PERIOD),
           node,
diff --git a/pkg/analyzer/lib/src/task/strong/checker.dart b/pkg/analyzer/lib/src/task/strong/checker.dart
index 4e2a092..6f9ac6e 100644
--- a/pkg/analyzer/lib/src/task/strong/checker.dart
+++ b/pkg/analyzer/lib/src/task/strong/checker.dart
@@ -1434,15 +1434,7 @@
         ]);
       }
     }
-    FunctionType concreteSubType = subType;
-    FunctionType concreteBaseType = baseType;
-    if (concreteSubType.typeFormals.isNotEmpty) {
-      if (concreteBaseType.typeFormals.isEmpty) {
-        concreteSubType = rules.instantiateToBounds(concreteSubType);
-      }
-    }
-
-    if (!rules.isOverrideSubtypeOf(concreteSubType, concreteBaseType)) {
+    if (!rules.isOverrideSubtypeOf(subType, baseType)) {
       ErrorCode errorCode;
       if (errorLocation is ExtendsClause) {
         errorCode = StrongModeCode.INVALID_METHOD_OVERRIDE_FROM_BASE;
diff --git a/pkg/analyzer/pubspec.yaml b/pkg/analyzer/pubspec.yaml
index eebe9df..e721451 100644
--- a/pkg/analyzer/pubspec.yaml
+++ b/pkg/analyzer/pubspec.yaml
@@ -8,6 +8,7 @@
 dependencies:
   args: '>=0.12.1 <0.14.0'
   charcode: ^1.1.0
+  collection: ^1.10.1
   crypto: '>=1.1.1 <3.0.0'
   front_end: 0.1.0-alpha.0
   glob: ^1.0.3
diff --git a/pkg/analyzer/test/dart/ast/ast_test.dart b/pkg/analyzer/test/dart/ast/ast_test.dart
index 3a887f8..494cb07 100644
--- a/pkg/analyzer/test/dart/ast/ast_test.dart
+++ b/pkg/analyzer/test/dart/ast/ast_test.dart
@@ -5,6 +5,7 @@
 library analyzer.test.dart.ast.ast_test;
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/src/dart/ast/token.dart';
 import 'package:analyzer/src/generated/testing/ast_test_factory.dart';
@@ -365,7 +366,7 @@
     AstNode parent = AstTestFactory.argumentList();
     AstNode firstNode = AstTestFactory.booleanLiteral(true);
     AstNode secondNode = AstTestFactory.booleanLiteral(false);
-    NodeList<AstNode> list = new NodeList<AstNode>(parent);
+    NodeList<AstNode> list = astFactory.nodeList/*<AstNode>*/(parent);
     list.insert(0, secondNode);
     list.insert(0, firstNode);
     expect(list, hasLength(2));
@@ -386,7 +387,7 @@
 
   void test_add_negative() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list.insert(-1, AstTestFactory.booleanLiteral(true));
       fail("Expected IndexOutOfBoundsException");
@@ -397,7 +398,7 @@
 
   void test_add_tooBig() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list.insert(1, AstTestFactory.booleanLiteral(true));
       fail("Expected IndexOutOfBoundsException");
@@ -413,7 +414,7 @@
     AstNode secondNode = AstTestFactory.booleanLiteral(false);
     firstNodes.add(firstNode);
     firstNodes.add(secondNode);
-    NodeList<AstNode> list = new NodeList<AstNode>(parent);
+    NodeList<AstNode> list = astFactory.nodeList/*<AstNode>*/(parent);
     list.addAll(firstNodes);
     expect(list, hasLength(2));
     expect(list[0], same(firstNode));
@@ -439,7 +440,7 @@
 
   void test_creation() {
     AstNode owner = AstTestFactory.argumentList();
-    NodeList<AstNode> list = new NodeList<AstNode>(owner);
+    NodeList<AstNode> list = astFactory.nodeList/*<AstNode>*/(owner);
     expect(list, isNotNull);
     expect(list, hasLength(0));
     expect(list.owner, same(owner));
@@ -447,7 +448,7 @@
 
   void test_get_negative() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list[-1];
       fail("Expected IndexOutOfBoundsException");
@@ -458,7 +459,7 @@
 
   void test_get_tooBig() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list[1];
       fail("Expected IndexOutOfBoundsException");
@@ -469,13 +470,13 @@
 
   void test_getBeginToken_empty() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     expect(list.beginToken, isNull);
   }
 
   void test_getBeginToken_nonEmpty() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     AstNode node = AstTestFactory
         .parenthesizedExpression(AstTestFactory.booleanLiteral(true));
     list.add(node);
@@ -484,13 +485,13 @@
 
   void test_getEndToken_empty() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     expect(list.endToken, isNull);
   }
 
   void test_getEndToken_nonEmpty() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     AstNode node = AstTestFactory
         .parenthesizedExpression(AstTestFactory.booleanLiteral(true));
     list.add(node);
@@ -507,7 +508,7 @@
     nodes.add(secondNode);
     nodes.add(thirdNode);
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     list.addAll(nodes);
     expect(list, hasLength(3));
     expect(list.indexOf(firstNode), 0);
@@ -526,7 +527,7 @@
     nodes.add(secondNode);
     nodes.add(thirdNode);
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     list.addAll(nodes);
     expect(list, hasLength(3));
     expect(list.removeAt(1), same(secondNode));
@@ -537,7 +538,7 @@
 
   void test_remove_negative() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list.removeAt(-1);
       fail("Expected IndexOutOfBoundsException");
@@ -548,7 +549,7 @@
 
   void test_remove_tooBig() {
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list.removeAt(1);
       fail("Expected IndexOutOfBoundsException");
@@ -566,7 +567,7 @@
     nodes.add(secondNode);
     nodes.add(thirdNode);
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     list.addAll(nodes);
     expect(list, hasLength(3));
     AstNode fourthNode = AstTestFactory.integer(0);
@@ -580,7 +581,7 @@
   void test_set_negative() {
     AstNode node = AstTestFactory.booleanLiteral(true);
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list[-1] = node;
       fail("Expected IndexOutOfBoundsException");
@@ -592,7 +593,7 @@
   void test_set_tooBig() {
     AstNode node = AstTestFactory.booleanLiteral(true);
     NodeList<AstNode> list =
-        new NodeList<AstNode>(AstTestFactory.argumentList());
+        astFactory.nodeList/*<AstNode>*/(AstTestFactory.argumentList());
     try {
       list[1] = node;
       fail("Expected IndexOutOfBoundsException");
@@ -795,47 +796,57 @@
 class SimpleStringLiteralTest extends ParserTestCase {
   void test_contentsEnd() {
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X")
             .contentsEnd,
         2);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString('"X"'), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString('"X"'), "X")
             .contentsEnd,
         2);
 
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString('"""X"""'), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString('"""X"""'), "X")
             .contentsEnd,
         4);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
             .contentsEnd,
         4);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("'''  \nX'''"), "X")
             .contentsEnd,
         7);
 
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
             .contentsEnd,
         3);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString('r"X"'), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString('r"X"'), "X")
             .contentsEnd,
         3);
 
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString('r"""X"""'), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString('r"""X"""'), "X")
             .contentsEnd,
         5);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
             .contentsEnd,
         5);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("r'''  \nX'''"), "X")
             .contentsEnd,
         8);
@@ -843,47 +854,57 @@
 
   void test_contentsOffset() {
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X")
             .contentsOffset,
         1);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("\"X\""), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("\"X\""), "X")
             .contentsOffset,
         1);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("\"\"\"X\"\"\""), "X")
             .contentsOffset,
         3);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
             .contentsOffset,
         3);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
             .contentsOffset,
         2);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r\"X\""), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r\"X\""), "X")
             .contentsOffset,
         2);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("r\"\"\"X\"\"\""), "X")
             .contentsOffset,
         4);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
             .contentsOffset,
         4);
     // leading whitespace
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("''' \ \nX''"), "X")
             .contentsOffset,
         6);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString('r""" \ \nX"""'), "X")
             .contentsOffset,
         7);
@@ -891,36 +912,44 @@
 
   void test_isMultiline() {
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X")
             .isMultiline,
         isFalse);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
             .isMultiline,
         isFalse);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("\"X\""), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("\"X\""), "X")
             .isMultiline,
         isFalse);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r\"X\""), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r\"X\""), "X")
             .isMultiline,
         isFalse);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
             .isMultiline,
         isTrue);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
             .isMultiline,
         isTrue);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("\"\"\"X\"\"\""), "X")
             .isMultiline,
         isTrue);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("r\"\"\"X\"\"\""), "X")
             .isMultiline,
         isTrue);
@@ -928,36 +957,45 @@
 
   void test_isRaw() {
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X").isRaw,
-        isFalse);
-    expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("\"X\""), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'X'"), "X")
             .isRaw,
         isFalse);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("\"X\""), "X")
+            .isRaw,
+        isFalse);
+    expect(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("\"\"\"X\"\"\""), "X")
             .isRaw,
         isFalse);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("'''X'''"), "X")
             .isRaw,
         isFalse);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'X'"), "X")
             .isRaw,
         isTrue);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r\"X\""), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r\"X\""), "X")
             .isRaw,
         isTrue);
     expect(
-        new SimpleStringLiteral(
+        astFactory
+            .simpleStringLiteral(
                 TokenFactory.tokenFromString("r\"\"\"X\"\"\""), "X")
             .isRaw,
         isTrue);
     expect(
-        new SimpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
+        astFactory
+            .simpleStringLiteral(TokenFactory.tokenFromString("r'''X'''"), "X")
             .isRaw,
         isTrue);
   }
@@ -966,25 +1004,25 @@
     // '
     {
       var token = TokenFactory.tokenFromString("'X'");
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isTrue);
     }
     // '''
     {
       var token = TokenFactory.tokenFromString("'''X'''");
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isTrue);
     }
     // "
     {
       var token = TokenFactory.tokenFromString('"X"');
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isFalse);
     }
     // """
     {
       var token = TokenFactory.tokenFromString('"""X"""');
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isFalse);
     }
   }
@@ -993,32 +1031,33 @@
     // r'
     {
       var token = TokenFactory.tokenFromString("r'X'");
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isTrue);
     }
     // r'''
     {
       var token = TokenFactory.tokenFromString("r'''X'''");
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isTrue);
     }
     // r"
     {
       var token = TokenFactory.tokenFromString('r"X"');
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isFalse);
     }
     // r"""
     {
       var token = TokenFactory.tokenFromString('r"""X"""');
-      var node = new SimpleStringLiteral(token, null);
+      var node = astFactory.simpleStringLiteral(token, null);
       expect(node.isSingleQuoted, isFalse);
     }
   }
 
   void test_simple() {
     Token token = TokenFactory.tokenFromString("'value'");
-    SimpleStringLiteral stringLiteral = new SimpleStringLiteral(token, "value");
+    SimpleStringLiteral stringLiteral =
+        astFactory.simpleStringLiteral(token, "value");
     expect(stringLiteral.literal, same(token));
     expect(stringLiteral.beginToken, same(token));
     expect(stringLiteral.endToken, same(token));
@@ -1034,7 +1073,7 @@
     {
       var ae = AstTestFactory.interpolationString("'a", "a");
       var cToken = new StringToken(TokenType.STRING, "ccc'", 10);
-      var cElement = new InterpolationString(cToken, 'ccc');
+      var cElement = astFactory.interpolationString(cToken, 'ccc');
       StringInterpolation node = AstTestFactory.string([ae, ae, cElement]);
       expect(node.contentsOffset, 1);
       expect(node.contentsEnd, 10 + 4 - 1);
@@ -1043,7 +1082,7 @@
     {
       var ae = AstTestFactory.interpolationString("'''a", "a");
       var cToken = new StringToken(TokenType.STRING, "ccc'''", 10);
-      var cElement = new InterpolationString(cToken, 'ccc');
+      var cElement = astFactory.interpolationString(cToken, 'ccc');
       StringInterpolation node = AstTestFactory.string([ae, ae, cElement]);
       expect(node.contentsOffset, 3);
       expect(node.contentsEnd, 10 + 4 - 1);
@@ -1052,7 +1091,7 @@
     {
       var ae = AstTestFactory.interpolationString('"""a', "a");
       var cToken = new StringToken(TokenType.STRING, 'ccc"""', 10);
-      var cElement = new InterpolationString(cToken, 'ccc');
+      var cElement = astFactory.interpolationString(cToken, 'ccc');
       StringInterpolation node = AstTestFactory.string([ae, ae, cElement]);
       expect(node.contentsOffset, 3);
       expect(node.contentsEnd, 10 + 4 - 1);
@@ -1061,7 +1100,7 @@
     {
       var ae = AstTestFactory.interpolationString("r'a", "a");
       var cToken = new StringToken(TokenType.STRING, "ccc'", 10);
-      var cElement = new InterpolationString(cToken, 'ccc');
+      var cElement = astFactory.interpolationString(cToken, 'ccc');
       StringInterpolation node = AstTestFactory.string([ae, ae, cElement]);
       expect(node.contentsOffset, 2);
       expect(node.contentsEnd, 10 + 4 - 1);
@@ -1070,7 +1109,7 @@
     {
       var ae = AstTestFactory.interpolationString("r'''a", "a");
       var cToken = new StringToken(TokenType.STRING, "ccc'''", 10);
-      var cElement = new InterpolationString(cToken, 'ccc');
+      var cElement = astFactory.interpolationString(cToken, 'ccc');
       StringInterpolation node = AstTestFactory.string([ae, ae, cElement]);
       expect(node.contentsOffset, 4);
       expect(node.contentsEnd, 10 + 4 - 1);
@@ -1079,7 +1118,7 @@
     {
       var ae = AstTestFactory.interpolationString('r"""a', "a");
       var cToken = new StringToken(TokenType.STRING, 'ccc"""', 10);
-      var cElement = new InterpolationString(cToken, 'ccc');
+      var cElement = astFactory.interpolationString(cToken, 'ccc');
       StringInterpolation node = AstTestFactory.string([ae, ae, cElement]);
       expect(node.contentsOffset, 4);
       expect(node.contentsEnd, 10 + 4 - 1);
@@ -1164,7 +1203,7 @@
     VariableDeclaration varDecl = AstTestFactory.variableDeclaration("a");
     TopLevelVariableDeclaration decl =
         AstTestFactory.topLevelVariableDeclaration2(Keyword.VAR, [varDecl]);
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
     expect(varDecl.documentationComment, isNull);
     decl.documentationComment = comment;
     expect(varDecl.documentationComment, isNotNull);
@@ -1173,7 +1212,7 @@
 
   void test_getDocumentationComment_onNode() {
     VariableDeclaration decl = AstTestFactory.variableDeclaration("a");
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
     decl.documentationComment = comment;
     expect(decl.documentationComment, isNotNull);
   }
diff --git a/pkg/analyzer/test/dart/element/builder_test.dart b/pkg/analyzer/test/dart/element/builder_test.dart
index c9b22c9..93faaaf 100644
--- a/pkg/analyzer/test/dart/element/builder_test.dart
+++ b/pkg/analyzer/test/dart/element/builder_test.dart
@@ -5,6 +5,7 @@
 library analyzer.test.dart.element.builder_test;
 
 import 'package:analyzer/dart/ast/ast.dart';
+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/src/dart/ast/ast.dart';
@@ -251,7 +252,7 @@
     TopLevelVariableDeclaration topLevelVariableDeclaration = AstTestFactory
         .topLevelVariableDeclaration(null, AstTestFactory.typeName4('int'),
             [AstTestFactory.variableDeclaration('V')]);
-    CompilationUnit unit = new CompilationUnit(
+    CompilationUnit unit = astFactory.compilationUnit(
         topLevelVariableDeclaration.beginToken,
         null,
         [],
diff --git a/pkg/analyzer/test/generated/element_resolver_test.dart b/pkg/analyzer/test/generated/element_resolver_test.dart
index 9824236..42f457d 100644
--- a/pkg/analyzer/test/generated/element_resolver_test.dart
+++ b/pkg/analyzer/test/generated/element_resolver_test.dart
@@ -5,6 +5,7 @@
 library analyzer.test.generated.element_resolver_test;
 
 import 'package:analyzer/dart/ast/ast.dart';
+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/type.dart';
@@ -546,7 +547,8 @@
       ..defineNameWithoutChecking('A', classA);
     // prepare "A.p"
     PrefixedIdentifier prefixed = AstTestFactory.identifier5('A', 'p');
-    CommentReference commentReference = new CommentReference(null, prefixed);
+    CommentReference commentReference =
+        astFactory.commentReference(null, prefixed);
     // resolve
     _resolveNode(commentReference);
     expect(prefixed.prefix.staticElement, classA);
@@ -565,7 +567,8 @@
       ..defineNameWithoutChecking('A', classA);
     // prepare "A.m"
     PrefixedIdentifier prefixed = AstTestFactory.identifier5('A', 'm');
-    CommentReference commentReference = new CommentReference(null, prefixed);
+    CommentReference commentReference =
+        astFactory.commentReference(null, prefixed);
     // resolve
     _resolveNode(commentReference);
     expect(prefixed.prefix.staticElement, classA);
@@ -584,7 +587,8 @@
       ..defineNameWithoutChecking('A', classA);
     // prepare "A.=="
     PrefixedIdentifier prefixed = AstTestFactory.identifier5('A', '==');
-    CommentReference commentReference = new CommentReference(null, prefixed);
+    CommentReference commentReference =
+        astFactory.commentReference(null, prefixed);
     // resolve
     _resolveNode(commentReference);
     expect(prefixed.prefix.staticElement, classA);
diff --git a/pkg/analyzer/test/generated/parser_test.dart b/pkg/analyzer/test/generated/parser_test.dart
index 87feeb2..d85fc09 100644
--- a/pkg/analyzer/test/generated/parser_test.dart
+++ b/pkg/analyzer/test/generated/parser_test.dart
@@ -5,6 +5,7 @@
 library analyzer.test.generated.parser_test;
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/error/error.dart';
@@ -5059,7 +5060,7 @@
   void test_parseAssignableSelector_none() {
     createParser(';');
     Expression expression =
-        parser.parseAssignableSelector(new SimpleIdentifier(null), true);
+        parser.parseAssignableSelector(astFactory.simpleIdentifier(null), true);
     expectNotNullIfNoErrors(expression);
     listener.assertNoErrors();
     expect(expression, new isInstanceOf<SimpleIdentifier>());
@@ -9416,8 +9417,9 @@
   }
 
   void test_parseFunctionDeclaration_function() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('f() {}');
     FunctionDeclaration declaration = parser.parseFunctionDeclaration(
         commentAndMetadata(comment), null, returnType);
@@ -9435,8 +9437,9 @@
   }
 
   void test_parseFunctionDeclaration_functionWithTypeParameters() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('f<E>() {}');
     FunctionDeclaration declaration = parser.parseFunctionDeclaration(
         commentAndMetadata(comment), null, returnType);
@@ -9455,8 +9458,9 @@
 
   void test_parseFunctionDeclaration_functionWithTypeParameters_comment() {
     enableGenericMethodComments = true;
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('f/*<E>*/() {}');
     FunctionDeclaration declaration = parser.parseFunctionDeclaration(
         commentAndMetadata(comment), null, returnType);
@@ -9474,8 +9478,9 @@
   }
 
   void test_parseFunctionDeclaration_getter() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('get p => 0;');
     FunctionDeclaration declaration = parser.parseFunctionDeclaration(
         commentAndMetadata(comment), null, returnType);
@@ -9493,8 +9498,9 @@
   }
 
   void test_parseFunctionDeclaration_setter() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('set p(v) {}');
     FunctionDeclaration declaration = parser.parseFunctionDeclaration(
         commentAndMetadata(comment), null, returnType);
@@ -9594,8 +9600,9 @@
   }
 
   void test_parseGetter_nonStatic() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('get a;');
     MethodDeclaration method =
         parser.parseGetter(commentAndMetadata(comment), null, null, returnType);
@@ -9613,9 +9620,10 @@
   }
 
   void test_parseGetter_static() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
     Token staticKeyword = TokenFactory.tokenFromKeyword(Keyword.STATIC);
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('get a => 42;');
     MethodDeclaration method = parser.parseGetter(
         commentAndMetadata(comment), null, staticKeyword, returnType);
@@ -9864,9 +9872,10 @@
   }
 
   void test_parseInitializedIdentifierList_type() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
     Token staticKeyword = TokenFactory.tokenFromKeyword(Keyword.STATIC);
-    TypeName type = new TypeName(new SimpleIdentifier(null), null);
+    TypeName type =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser("a = 1, b, c = 3;");
     FieldDeclaration declaration = parser.parseInitializedIdentifierList(
         commentAndMetadata(comment), staticKeyword, null, type);
@@ -9883,7 +9892,7 @@
   }
 
   void test_parseInitializedIdentifierList_var() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
     Token staticKeyword = TokenFactory.tokenFromKeyword(Keyword.STATIC);
     Token varKeyword = TokenFactory.tokenFromKeyword(Keyword.VAR);
     createParser('a = 1, b, c = 3;');
@@ -11075,8 +11084,9 @@
   }
 
   void test_parseOperator() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('operator +(A a);');
     MethodDeclaration method =
         parser.parseOperator(commentAndMetadata(comment), null, returnType);
@@ -11733,8 +11743,9 @@
   }
 
   void test_parseSetter_nonStatic() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('set a(var x);');
     MethodDeclaration method =
         parser.parseSetter(commentAndMetadata(comment), null, null, returnType);
@@ -11753,9 +11764,10 @@
   }
 
   void test_parseSetter_static() {
-    Comment comment = Comment.createDocumentationComment(new List<Token>(0));
+    Comment comment = astFactory.documentationComment(new List<Token>(0));
     Token staticKeyword = TokenFactory.tokenFromKeyword(Keyword.STATIC);
-    TypeName returnType = new TypeName(new SimpleIdentifier(null), null);
+    TypeName returnType =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('set a(var x) {}');
     MethodDeclaration method = parser.parseSetter(
         commentAndMetadata(comment), null, staticKeyword, returnType);
@@ -13121,7 +13133,8 @@
   }
 
   void test_parseVariableDeclarationListAfterType_type() {
-    TypeName type = new TypeName(new SimpleIdentifier(null), null);
+    TypeName type =
+        astFactory.typeName(astFactory.simpleIdentifier(null), null);
     createParser('a');
     VariableDeclarationList declarationList =
         parser.parseVariableDeclarationListAfterType(
diff --git a/pkg/analyzer/test/generated/resolver_test.dart b/pkg/analyzer/test/generated/resolver_test.dart
index 416f980..e87206b 100644
--- a/pkg/analyzer/test/generated/resolver_test.dart
+++ b/pkg/analyzer/test/generated/resolver_test.dart
@@ -7,6 +7,7 @@
 import 'dart:collection';
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
@@ -3462,7 +3463,7 @@
   void test_visitTypeName_noParameters_noArguments_undefined() {
     SimpleIdentifier id = AstTestFactory.identifier3("unknown")
       ..staticElement = new _StaleElement();
-    TypeName typeName = new TypeName(id, null);
+    TypeName typeName = astFactory.typeName(id, null);
     _resolveNode(typeName, []);
     expect(typeName.type, UndefinedTypeImpl.instance);
     expect(typeName.name.staticElement, null);
@@ -3503,7 +3504,7 @@
     SimpleIdentifier suffix = AstTestFactory.identifier3("unknownSuffix")
       ..staticElement = new _StaleElement();
     TypeName typeName =
-        new TypeName(AstTestFactory.identifier(prefix, suffix), null);
+        astFactory.typeName(AstTestFactory.identifier(prefix, suffix), null);
     _resolveNode(typeName, []);
     expect(typeName.type, UndefinedTypeImpl.instance);
     expect(prefix.staticElement, null);
@@ -3638,5 +3639,5 @@
   get kind => throw "_StaleElement's kind shouldn't be accessed";
 
   @override
-  accept(_) => throw "_StaleElement shouldn't be visited";
+  /*=T*/ accept/*<T>*/(_) => throw "_StaleElement shouldn't be visited";
 }
diff --git a/pkg/analyzer/test/generated/type_system_test.dart b/pkg/analyzer/test/generated/type_system_test.dart
index 6aa2ad1..c555954 100644
--- a/pkg/analyzer/test/generated/type_system_test.dart
+++ b/pkg/analyzer/test/generated/type_system_test.dart
@@ -1608,15 +1608,42 @@
     DartType u = TypeBuilder.variable("U", bound: intType);
     DartType v = TypeBuilder.variable("V", bound: u);
 
+    DartType a = TypeBuilder.variable("A");
+    DartType b = TypeBuilder.variable("B", bound: a);
+    DartType c = TypeBuilder.variable("C", bound: intType);
+    DartType d = TypeBuilder.variable("D", bound: c);
+
     _checkIsStrictSubtypeOf(
         TypeBuilder.function(types: [s, t], required: [s], result: t),
+        TypeBuilder.function(
+            types: [a, b], required: [dynamicType], result: dynamicType));
+
+    _checkIsNotSubtypeOf(
+        TypeBuilder.function(types: [u, v], required: [u], result: v),
+        TypeBuilder.function(
+            types: [c, d], required: [objectType], result: objectType));
+
+    _checkIsNotSubtypeOf(
+        TypeBuilder.function(types: [u, v], required: [u], result: v),
+        TypeBuilder
+            .function(types: [c, d], required: [intType], result: intType));
+  }
+
+  void test_genericFunction_genericDoesNotSubtypeNonGeneric() {
+    DartType s = TypeBuilder.variable("S");
+    DartType t = TypeBuilder.variable("T", bound: s);
+    DartType u = TypeBuilder.variable("U", bound: intType);
+    DartType v = TypeBuilder.variable("V", bound: u);
+
+    _checkIsNotSubtypeOf(
+        TypeBuilder.function(types: [s, t], required: [s], result: t),
         TypeBuilder.function(required: [dynamicType], result: dynamicType));
 
     _checkIsNotSubtypeOf(
         TypeBuilder.function(types: [u, v], required: [u], result: v),
         TypeBuilder.function(required: [objectType], result: objectType));
 
-    _checkIsStrictSubtypeOf(
+    _checkIsNotSubtypeOf(
         TypeBuilder.function(types: [u, v], required: [u], result: v),
         TypeBuilder.function(required: [intType], result: intType));
   }
diff --git a/pkg/analyzer/test/generated/utilities_test.dart b/pkg/analyzer/test/generated/utilities_test.dart
index 88b88d5..050a6c1 100644
--- a/pkg/analyzer/test/generated/utilities_test.dart
+++ b/pkg/analyzer/test/generated/utilities_test.dart
@@ -7,6 +7,7 @@
 import 'dart:collection';
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/src/dart/ast/token.dart';
@@ -1606,7 +1607,7 @@
             dynamic exception, StackTrace stackTrace) {
       handlerInvoked = true;
     });
-    new NullLiteral(null).accept(visitor);
+    astFactory.nullLiteral(null).accept(visitor);
     expect(handlerInvoked, isTrue);
   }
 }
@@ -3063,8 +3064,7 @@
       AstTestFactory.fieldDeclaration2(
           false, null, [AstTestFactory.variableDeclaration("f")])
     ]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     node.nativeClause = AstTestFactory.nativeClause("");
@@ -3087,8 +3087,7 @@
         AstTestFactory.typeName4("B"),
         AstTestFactory.withClause([AstTestFactory.typeName4("C")]),
         AstTestFactory.implementsClause([AstTestFactory.typeName4("D")]));
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_classTypeAlias_4());
@@ -3100,15 +3099,15 @@
   }
 
   void test_comment() {
-    Comment node = Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
-    node.references
-        .add(new CommentReference(null, AstTestFactory.identifier3("x")));
+    Comment node = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
+    node.references.add(
+        astFactory.commentReference(null, AstTestFactory.identifier3("x")));
     _assertReplace(node, new ListGetter_NodeReplacerTest_test_comment(0));
   }
 
   void test_commentReference() {
     CommentReference node =
-        new CommentReference(null, AstTestFactory.identifier3("x"));
+        astFactory.commentReference(null, AstTestFactory.identifier3("x"));
     _assertReplace(node, new Getter_NodeReplacerTest_test_commentReference());
   }
 
@@ -3151,8 +3150,7 @@
               false, "x", AstTestFactory.integer(0))
         ],
         AstTestFactory.emptyFunctionBody());
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     node.redirectedConstructor =
@@ -3196,8 +3194,7 @@
   void test_declaredIdentifier() {
     DeclaredIdentifier node =
         AstTestFactory.declaredIdentifier4(AstTestFactory.typeName4("C"), "i");
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_declaredIdentifier());
@@ -3223,8 +3220,8 @@
   }
 
   void test_enumConstantDeclaration() {
-    EnumConstantDeclaration node = new EnumConstantDeclaration(
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST),
+    EnumConstantDeclaration node = astFactory.enumConstantDeclaration(
+        astFactory.endOfLineComment(EMPTY_TOKEN_LIST),
         [AstTestFactory.annotation(AstTestFactory.identifier3("a"))],
         AstTestFactory.identifier3("C"));
     _assertReplace(
@@ -3234,8 +3231,7 @@
 
   void test_enumDeclaration() {
     EnumDeclaration node = AstTestFactory.enumDeclaration2("E", ["ONE", "TWO"]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_enumDeclaration());
@@ -3246,8 +3242,7 @@
     ExportDirective node = AstTestFactory.exportDirective2("", [
       AstTestFactory.hideCombinator2(["C"])
     ]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _testNamespaceDirective(node);
@@ -3279,8 +3274,7 @@
         null,
         AstTestFactory.typeName4("C"),
         [AstTestFactory.variableDeclaration("c")]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_fieldDeclaration());
@@ -3293,8 +3287,7 @@
         AstTestFactory.typeName4("C"),
         "f",
         AstTestFactory.formalParameterList());
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata = [
       AstTestFactory.annotation(AstTestFactory.identifier3("a"))
     ];
@@ -3380,8 +3373,7 @@
         "f",
         AstTestFactory.functionExpression2(AstTestFactory.formalParameterList(),
             AstTestFactory.blockFunctionBody(AstTestFactory.block())));
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(
@@ -3431,8 +3423,7 @@
         "F",
         AstTestFactory.typeParameterList(["E"]),
         AstTestFactory.formalParameterList());
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(
@@ -3449,8 +3440,7 @@
     FunctionTypedFormalParameter node = AstTestFactory
         .functionTypedFormalParameter(AstTestFactory.typeName4("R"), "f",
             [AstTestFactory.simpleFormalParameter3("p")]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata = [
       AstTestFactory.annotation(AstTestFactory.identifier3("a"))
     ];
@@ -3489,8 +3479,7 @@
       AstTestFactory.showCombinator2(["A"]),
       AstTestFactory.hideCombinator2(["B"])
     ]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_importDirective());
@@ -3542,8 +3531,7 @@
 
   void test_libraryDirective() {
     LibraryDirective node = AstTestFactory.libraryDirective2("lib");
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_libraryDirective());
@@ -3590,8 +3578,7 @@
         AstTestFactory.identifier3("m"),
         AstTestFactory.formalParameterList(),
         AstTestFactory.blockFunctionBody(AstTestFactory.block()));
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_methodDeclaration());
@@ -3638,8 +3625,7 @@
 
   void test_partDirective() {
     PartDirective node = AstTestFactory.partDirective2("");
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _testUriBasedDirective(node);
@@ -3648,8 +3634,7 @@
   void test_partOfDirective() {
     PartOfDirective node = AstTestFactory
         .partOfDirective(AstTestFactory.libraryIdentifier2(["lib"]));
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(node, new Getter_NodeReplacerTest_test_partOfDirective());
@@ -3706,8 +3691,7 @@
   void test_simpleFormalParameter() {
     SimpleFormalParameter node = AstTestFactory.simpleFormalParameter4(
         AstTestFactory.typeName4("T"), "p");
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata = [
       AstTestFactory.annotation(AstTestFactory.identifier3("a"))
     ];
@@ -3768,8 +3752,7 @@
     TopLevelVariableDeclaration node = AstTestFactory
         .topLevelVariableDeclaration(null, AstTestFactory.typeName4("T"),
             [AstTestFactory.variableDeclaration("t")]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(
@@ -3819,8 +3802,7 @@
   void test_variableDeclaration() {
     VariableDeclaration node =
         AstTestFactory.variableDeclaration2("a", AstTestFactory.nullLiteral());
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(
@@ -3835,8 +3817,7 @@
         null,
         AstTestFactory.typeName4("T"),
         [AstTestFactory.variableDeclaration("a")]);
-    node.documentationComment =
-        Comment.createEndOfLineComment(EMPTY_TOKEN_LIST);
+    node.documentationComment = astFactory.endOfLineComment(EMPTY_TOKEN_LIST);
     node.metadata
         .add(AstTestFactory.annotation(AstTestFactory.identifier3("a")));
     _assertReplace(
diff --git a/pkg/analyzer/test/src/context/mock_sdk.dart b/pkg/analyzer/test/src/context/mock_sdk.dart
index 464dec0..69e212e 100644
--- a/pkg/analyzer/test/src/context/mock_sdk.dart
+++ b/pkg/analyzer/test/src/context/mock_sdk.dart
@@ -351,7 +351,9 @@
   PackageBundle _bundle;
 
   MockSdk(
-      {bool dartAsync: true, resource.MemoryResourceProvider resourceProvider})
+      {bool generateSummaryFiles: false,
+      bool dartAsync: true,
+      resource.MemoryResourceProvider resourceProvider})
       : provider = resourceProvider ?? new resource.MemoryResourceProvider(),
         sdkLibraries = dartAsync ? _LIBRARIES : [_LIB_CORE],
         uriMap = dartAsync ? FULL_URI_MAP : NO_ASYNC_URI_MAP {
@@ -365,6 +367,13 @@
         provider.convertPath(
             '$sdkRoot/lib/_internal/sdk_library_metadata/lib/libraries.dart'),
         librariesContent);
+    if (generateSummaryFiles) {
+      List<int> bytes = _computeLinkedBundleBytes();
+      provider.newFileWithBytes(
+          provider.convertPath('/lib/_internal/spec.sum'), bytes);
+      provider.newFileWithBytes(
+          provider.convertPath('/lib/_internal/strong.sum'), bytes);
+    }
   }
 
   @override
@@ -422,12 +431,14 @@
   @override
   PackageBundle getLinkedBundle() {
     if (_bundle == null) {
-      List<Source> librarySources = sdkLibraries
-          .map((SdkLibrary library) => mapDartUri(library.shortName))
-          .toList();
-      List<int> bytes = new SummaryBuilder(
-              librarySources, context, context.analysisOptions.strongMode)
-          .build();
+      resource.File summaryFile =
+          provider.getFile(provider.convertPath('/lib/_internal/spec.sum'));
+      List<int> bytes;
+      if (summaryFile.exists) {
+        bytes = summaryFile.readAsBytesSync();
+      } else {
+        bytes = _computeLinkedBundleBytes();
+      }
       _bundle = new PackageBundle.fromBuffer(bytes);
     }
     return _bundle;
@@ -467,6 +478,18 @@
     String newContent = updateContent(content);
     provider.updateFile(path, newContent);
   }
+
+  /**
+   * Compute the bytes of the linked bundle associated with this SDK.
+   */
+  List<int> _computeLinkedBundleBytes() {
+    List<Source> librarySources = sdkLibraries
+        .map((SdkLibrary library) => mapDartUri(library.shortName))
+        .toList();
+    return new SummaryBuilder(
+            librarySources, context, context.analysisOptions.strongMode)
+        .build();
+  }
 }
 
 class _MockSdkLibrary implements SdkLibrary {
diff --git a/pkg/analyzer/test/src/dart/analysis/driver_test.dart b/pkg/analyzer/test/src/dart/analysis/driver_test.dart
index 6b4231e..0ddaac5 100644
--- a/pkg/analyzer/test/src/dart/analysis/driver_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/driver_test.dart
@@ -16,6 +16,7 @@
 import 'package:analyzer/src/dart/analysis/driver.dart';
 import 'package:analyzer/src/dart/analysis/file_state.dart';
 import 'package:analyzer/src/dart/analysis/status.dart';
+import 'package:analyzer/src/dart/analysis/top_level_declaration.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/generated/engine.dart' show AnalysisOptionsImpl;
 import 'package:analyzer/src/generated/source.dart';
@@ -379,6 +380,56 @@
     }
   }
 
+  test_errors_uriDoesNotExist_export() async {
+    addTestFile(r'''
+export 'foo.dart';
+''');
+
+    AnalysisResult result = await driver.getResult(testFile);
+    List<AnalysisError> errors = result.errors;
+    expect(errors, hasLength(1));
+    expect(errors[0].errorCode, CompileTimeErrorCode.URI_DOES_NOT_EXIST);
+  }
+
+  test_errors_uriDoesNotExist_import() async {
+    addTestFile(r'''
+import 'foo.dart';
+''');
+
+    AnalysisResult result = await driver.getResult(testFile);
+    List<AnalysisError> errors = result.errors;
+    expect(errors, hasLength(1));
+    expect(errors[0].errorCode, CompileTimeErrorCode.URI_DOES_NOT_EXIST);
+  }
+
+  test_errors_uriDoesNotExist_import_deferred() async {
+    addTestFile(
+        r'''
+import 'foo.dart' deferred as foo;
+main() {
+  foo.loadLibrary();
+}
+''',
+        priority: true);
+
+    AnalysisResult result = await driver.getResult(testFile);
+    List<AnalysisError> errors = result.errors;
+    expect(errors, hasLength(1));
+    expect(errors[0].errorCode, CompileTimeErrorCode.URI_DOES_NOT_EXIST);
+  }
+
+  test_errors_uriDoesNotExist_part() async {
+    addTestFile(r'''
+library lib;
+part 'foo.dart';
+''');
+
+    AnalysisResult result = await driver.getResult(testFile);
+    List<AnalysisError> errors = result.errors;
+    expect(errors, hasLength(1));
+    expect(errors[0].errorCode, CompileTimeErrorCode.URI_DOES_NOT_EXIST);
+  }
+
   test_getFilesReferencingName() async {
     var a = _p('/test/bin/a.dart');
     var b = _p('/test/bin/b.dart');
@@ -588,6 +639,11 @@
 String z = "string";
 ''');
 
+    driver.addFile(a);
+    driver.addFile(b);
+    driver.addFile(c);
+    driver.addFile(d);
+
     // Analysis of my_pkg/bin/a.dart produces no error because
     // file:///my_pkg/bin/a.dart imports package:my_pkg/c.dart, and
     // package:my_pkg/c.dart's import is erroneous, causing y's reference to z
@@ -610,6 +666,14 @@
     }
   }
 
+  test_getResult_noErrors_ifNotAdded() async {
+    var a = _p('/test/lib/a.dart');
+    provider.newFile(a, 'A a = null;');
+
+    AnalysisResult result = await driver.getResult(a);
+    expect(result.errors, isEmpty);
+  }
+
   test_getResult_notDartFile() async {
     var path = _p('/test/lib/test.txt');
     provider.newFile(path, 'foo bar');
@@ -733,6 +797,49 @@
     expect(result1.unit, isNotNull);
   }
 
+  test_getTopLevelNameDeclarations() async {
+    var a = _p('/test/lib/a.dart');
+    var b = _p('/test/lib/b.dart');
+    var c = _p('/test/lib/c.dart');
+    var d = _p('/test/lib/d.dart');
+
+    provider.newFile(a, 'class A {}');
+    provider.newFile(b, 'export "a.dart", class B {}');
+    provider.newFile(c, 'import "d.dart"; class C {}');
+    provider.newFile(d, 'class D {}');
+
+    driver.addFile(a);
+    driver.addFile(b);
+    driver.addFile(c);
+    // Don't add d.dart, it is referenced implicitly.
+
+    void assertDeclarations(List<TopLevelDeclarationInSource> declarations,
+        List<String> expectedFiles, List<bool> expectedIsExported) {
+      expect(expectedFiles, hasLength(expectedIsExported.length));
+      for (int i = 0; i < expectedFiles.length; i++) {
+        expect(declarations,
+            contains(predicate((TopLevelDeclarationInSource declaration) {
+          return declaration.source.fullName == expectedFiles[i] &&
+              declaration.isExported == expectedIsExported[i];
+        })));
+      }
+    }
+
+    assertDeclarations(
+        await driver.getTopLevelNameDeclarations('A'), [a, b], [false, true]);
+
+    assertDeclarations(
+        await driver.getTopLevelNameDeclarations('B'), [b], [false]);
+
+    assertDeclarations(
+        await driver.getTopLevelNameDeclarations('C'), [c], [false]);
+
+    assertDeclarations(
+        await driver.getTopLevelNameDeclarations('D'), [d], [false]);
+
+    assertDeclarations(await driver.getTopLevelNameDeclarations('X'), [], []);
+  }
+
   test_knownFiles() async {
     var a = _p('/test/lib/a.dart');
     var b = _p('/test/lib/b.dart');
@@ -756,6 +863,23 @@
     expect(driver.knownFiles, contains(b));
   }
 
+  test_parseFile_shouldRefresh() async {
+    var p = _p('/test/bin/a.dart');
+
+    provider.newFile(p, 'class A {}');
+    driver.addFile(p);
+
+    // Get the result, so force the file reading.
+    await driver.getResult(p);
+
+    // Update the file.
+    provider.newFile(p, 'class A2 {}');
+
+    ParseResult parseResult = await driver.parseFile(p);
+    var clazz = parseResult.unit.declarations[0] as ClassDeclaration;
+    expect(clazz.name.name, 'A2');
+  }
+
   test_part_getResult_afterLibrary() async {
     var a = _p('/test/lib/a.dart');
     var b = _p('/test/lib/b.dart');
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 a97f9c3..bb45ad1 100644
--- a/pkg/analyzer/test/src/dart/analysis/file_state_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/file_state_test.dart
@@ -11,6 +11,7 @@
 import 'package:analyzer/src/dart/analysis/byte_store.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart' show PerformanceLog;
 import 'package:analyzer/src/dart/analysis/file_state.dart';
+import 'package:analyzer/src/dart/analysis/top_level_declaration.dart';
 import 'package:analyzer/src/generated/engine.dart'
     show AnalysisOptions, AnalysisOptionsImpl;
 import 'package:analyzer/src/generated/source.dart';
@@ -57,6 +58,201 @@
         provider, sourceFactory, analysisOptions, new Uint32List(0), '');
   }
 
+  test_exportedTopLevelDeclarations_export() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    provider.newFile(
+        a,
+        r'''
+class A {}
+''');
+    provider.newFile(
+        b,
+        r'''
+export 'a.dart';
+class B {}
+''');
+    FileState file = fileSystemState.getFileForPath(b);
+    Map<String, TopLevelDeclaration> declarations =
+        file.exportedTopLevelDeclarations;
+    expect(declarations.keys, unorderedEquals(['A', 'B']));
+  }
+
+  test_exportedTopLevelDeclarations_export2_show() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    String c = _p('/aaa/lib/c.dart');
+    provider.newFile(
+        a,
+        r'''
+class A1 {}
+class A2 {}
+class A3 {}
+''');
+    provider.newFile(
+        b,
+        r'''
+export 'a.dart' show A1, A2;
+class B1 {}
+class B2 {}
+''');
+    provider.newFile(
+        c,
+        r'''
+export 'b.dart' show A2, A3, B1;
+class C {}
+''');
+    _assertExportedTopLevelDeclarations(c, ['A2', 'B1', 'C']);
+  }
+
+  test_exportedTopLevelDeclarations_export_flushOnChange() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    provider.newFile(
+        a,
+        r'''
+class A {}
+''');
+    provider.newFile(
+        b,
+        r'''
+export 'a.dart';
+class B {}
+''');
+
+    // Initial exported declarations.
+    _assertExportedTopLevelDeclarations(b, ['A', 'B']);
+
+    // Update a.dart, so a.dart and b.dart exported declarations are flushed.
+    provider.newFile(a, 'class A {} class A2 {}');
+    fileSystemState.getFileForPath(a).refresh();
+    _assertExportedTopLevelDeclarations(b, ['A', 'A2', 'B']);
+  }
+
+  test_exportedTopLevelDeclarations_export_hide() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    provider.newFile(
+        a,
+        r'''
+class A1 {}
+class A2 {}
+class A3 {}
+''');
+    provider.newFile(
+        b,
+        r'''
+export 'a.dart' hide A2;
+class B {}
+''');
+    _assertExportedTopLevelDeclarations(b, ['A1', 'A3', 'B']);
+  }
+
+  test_exportedTopLevelDeclarations_export_preferLocal() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    provider.newFile(
+        a,
+        r'''
+class V {}
+''');
+    provider.newFile(
+        b,
+        r'''
+export 'a.dart';
+int V;
+''');
+    FileState file = fileSystemState.getFileForPath(b);
+    Map<String, TopLevelDeclaration> declarations =
+        file.exportedTopLevelDeclarations;
+    expect(declarations.keys, unorderedEquals(['V']));
+    expect(declarations['V'].kind, TopLevelDeclarationKind.variable);
+  }
+
+  test_exportedTopLevelDeclarations_export_show() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    provider.newFile(
+        a,
+        r'''
+class A1 {}
+class A2 {}
+''');
+    provider.newFile(
+        b,
+        r'''
+export 'a.dart' show A2;
+class B {}
+''');
+    _assertExportedTopLevelDeclarations(b, ['A2', 'B']);
+  }
+
+  test_exportedTopLevelDeclarations_export_show2() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    String c = _p('/aaa/lib/c.dart');
+    String d = _p('/aaa/lib/d.dart');
+    provider.newFile(
+        a,
+        r'''
+export 'b.dart' show Foo;
+export 'c.dart' show Bar;
+''');
+    provider.newFile(
+        b,
+        r'''
+export 'd.dart';
+''');
+    provider.newFile(
+        c,
+        r'''
+export 'd.dart';
+''');
+    provider.newFile(
+        d,
+        r'''
+class Foo {}
+class Bar {}
+''');
+    _assertExportedTopLevelDeclarations(a, ['Foo', 'Bar']);
+  }
+
+  test_exportedTopLevelDeclarations_import() {
+    String a = _p('/aaa/lib/a.dart');
+    String b = _p('/aaa/lib/b.dart');
+    provider.newFile(
+        a,
+        r'''
+class A {}
+''');
+    provider.newFile(
+        b,
+        r'''
+import 'a.dart';
+class B {}
+''');
+    _assertExportedTopLevelDeclarations(b, ['B']);
+  }
+
+  test_exportedTopLevelDeclarations_parts() {
+    String a = _p('/aaa/lib/a.dart');
+    String a2 = _p('/aaa/lib/a2.dart');
+    provider.newFile(
+        a,
+        r'''
+library lib;
+part 'a2.dart';
+class A1 {}
+''');
+    provider.newFile(
+        a2,
+        r'''
+part of lib;
+class A2 {}
+''');
+    _assertExportedTopLevelDeclarations(a, ['A1', 'A2']);
+  }
+
   test_getFileForPath_doesNotExist() {
     String path = _p('/aaa/lib/a.dart');
     FileState file = fileSystemState.getFileForPath(path);
@@ -280,6 +476,49 @@
     expect(file.apiSignature, signature);
   }
 
+  test_topLevelDeclarations() {
+    String path = _p('/aaa/lib/a.dart');
+    provider.newFile(
+        path,
+        r'''
+class C {}
+typedef F();
+enum E {E1, E2}
+void f() {}
+var V1;
+get V2 => null;
+set V3(_) {}
+get V4 => null;
+set V4(_) {}
+
+class _C {}
+typedef _F();
+enum _E {E1, E2}
+void _f() {}
+var _V1;
+get _V2 => null;
+set _V3(_) {}
+''');
+    FileState file = fileSystemState.getFileForPath(path);
+
+    Map<String, TopLevelDeclaration> declarations = file.topLevelDeclarations;
+
+    void assertHas(String name, TopLevelDeclarationKind kind) {
+      expect(declarations[name]?.kind, kind);
+    }
+
+    expect(declarations.keys,
+        unorderedEquals(['C', 'F', 'E', 'f', 'V1', 'V2', 'V3', 'V4']));
+    assertHas('C', TopLevelDeclarationKind.type);
+    assertHas('F', TopLevelDeclarationKind.type);
+    assertHas('E', TopLevelDeclarationKind.type);
+    assertHas('f', TopLevelDeclarationKind.function);
+    assertHas('V1', TopLevelDeclarationKind.variable);
+    assertHas('V2', TopLevelDeclarationKind.variable);
+    assertHas('V3', TopLevelDeclarationKind.variable);
+    assertHas('V4', TopLevelDeclarationKind.variable);
+  }
+
   test_transitiveFiles() {
     String pa = _p('/aaa/lib/a.dart');
     String pb = _p('/aaa/lib/b.dart');
@@ -394,6 +633,13 @@
     _assertFilesWithoutTransitiveSignatures([fa, fb, fc]);
   }
 
+  void _assertExportedTopLevelDeclarations(String path, List<String> expected) {
+    FileState file = fileSystemState.getFileForPath(path);
+    Map<String, TopLevelDeclaration> declarations =
+        file.exportedTopLevelDeclarations;
+    expect(declarations.keys, unorderedEquals(expected));
+  }
+
   void _assertFilesWithoutTransitiveFiles(List<FileState> expected) {
     var actual = fileSystemState.test.filesWithoutTransitiveFiles;
     expect(actual, unorderedEquals(expected));
diff --git a/pkg/analyzer/test/src/dart/analysis/search_test.dart b/pkg/analyzer/test/src/dart/analysis/search_test.dart
index e473ffc..3b830fb 100644
--- a/pkg/analyzer/test/src/dart/analysis/search_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/search_test.dart
@@ -121,27 +121,72 @@
     await _verifyReferences(element, expected);
   }
 
-  @failingTest
   test_searchReferences_CompilationUnitElement() async {
-    provider.newFile(
-        _p('$testProject/my_part.dart'),
-        '''
-part of lib;
-''');
+    provider.newFile(_p('$testProject/foo.dart'), '');
     await _resolveTestUnit('''
-library lib;
-part 'my_part.dart';
+import 'foo.dart'; // import
+export 'foo.dart'; // export
 ''');
-    CompilationUnitElement element = _findElementAtString('my_part');
+    CompilationUnitElement element =
+        testLibraryElement.imports[0].importedLibrary.definingCompilationUnit;
+    int uriLength = "'foo.dart'".length;
     var expected = [
-      _expectIdQ(element.library.definingCompilationUnit,
-          SearchResultKind.REFERENCE, "'my_part.dart'",
-          length: "'my_part.dart'".length)
+      _expectIdQ(
+          testUnitElement, SearchResultKind.REFERENCE, "'foo.dart'; // import",
+          length: uriLength),
+      _expectIdQ(
+          testUnitElement, SearchResultKind.REFERENCE, "'foo.dart'; // export",
+          length: uriLength),
     ];
     await _verifyReferences(element, expected);
   }
 
-  test_searchReferences_ConstructorElement() async {
+  test_searchReferences_ConstructorElement_default() async {
+    await _resolveTestUnit('''
+class A {
+  A() {}
+}
+main() {
+  new A();
+}
+''');
+    ConstructorElement element = _findElementAtString('A() {}');
+    Element mainElement = _findElement('main');
+    var expected = [
+      _expectIdQ(mainElement, SearchResultKind.REFERENCE, '();', length: 0)
+    ];
+    await _verifyReferences(element, expected);
+  }
+
+  test_searchReferences_ConstructorElement_default_otherFile() async {
+    String other = _p('$testProject/other.dart');
+    String otherCode = '''
+import 'test.dart';
+main() {
+  new A(); // in other
+}
+''';
+    provider.newFile(other, otherCode);
+    driver.addFile(other);
+
+    await _resolveTestUnit('''
+class A {
+  A() {}
+}
+''');
+    ConstructorElement element = _findElementAtString('A() {}');
+
+    CompilationUnit otherUnit = (await driver.getResult(other)).unit;
+    Element main = otherUnit.element.functions[0];
+    var expected = [
+      new ExpectedResult(main, SearchResultKind.REFERENCE,
+          otherCode.indexOf('(); // in other'), 0,
+          isResolved: true, isQualified: true)
+    ];
+    await _verifyReferences(element, expected);
+  }
+
+  test_searchReferences_ConstructorElement_named() async {
     await _resolveTestUnit('''
 class A {
   A.named() {}
@@ -154,7 +199,7 @@
     Element mainElement = _findElement('main');
     var expected = [
       _expectIdQ(mainElement, SearchResultKind.REFERENCE, '.named();',
-          length: 6)
+          length: '.named'.length)
     ];
     await _verifyReferences(element, expected);
   }
@@ -300,6 +345,83 @@
     await _verifyReferences(element, expected);
   }
 
+  test_searchReferences_ImportElement_noPrefix() async {
+    await _resolveTestUnit('''
+import 'dart:math' show max, PI, Random hide min;
+export 'dart:math' show max, PI, Random hide min;
+main() {
+  print(PI);
+  print(new Random());
+  print(max(1, 2));
+}
+Random bar() => null;
+''');
+    ImportElement element = testLibraryElement.imports[0];
+    Element mainElement = await _findElement('main');
+    Element barElement = await _findElement('bar');
+    var kind = SearchResultKind.REFERENCE;
+    var expected = [
+      _expectId(mainElement, kind, 'PI);', length: 0),
+      _expectId(mainElement, kind, 'Random()', length: 0),
+      _expectId(mainElement, kind, 'max(', length: 0),
+      _expectId(barElement, kind, 'Random bar()', length: 0),
+    ];
+    await _verifyReferences(element, expected);
+  }
+
+  test_searchReferences_ImportElement_withPrefix() async {
+    await _resolveTestUnit('''
+import 'dart:math' as math show max, PI, Random hide min;
+export 'dart:math' show max, PI, Random hide min;
+main() {
+  print(math.PI);
+  print(new math.Random());
+  print(math.max(1, 2));
+}
+math.Random bar() => null;
+''');
+    ImportElement element = testLibraryElement.imports[0];
+    Element mainElement = await _findElement('main');
+    Element barElement = await _findElement('bar');
+    var kind = SearchResultKind.REFERENCE;
+    var length = 'math.'.length;
+    var expected = [
+      _expectId(mainElement, kind, 'math.PI);', length: length),
+      _expectId(mainElement, kind, 'math.Random()', length: length),
+      _expectId(mainElement, kind, 'math.max(', length: length),
+      _expectId(barElement, kind, 'math.Random bar()', length: length),
+    ];
+    await _verifyReferences(element, expected);
+  }
+
+  test_searchReferences_ImportElement_withPrefix_forMultipleImports() async {
+    await _resolveTestUnit('''
+import 'dart:async' as p;
+import 'dart:math' as p;
+main() {
+  p.Random;
+  p.Future;
+}
+''');
+    Element mainElement = await _findElement('main');
+    var kind = SearchResultKind.REFERENCE;
+    var length = 'p.'.length;
+    {
+      ImportElement element = testLibraryElement.imports[0];
+      var expected = [
+        _expectId(mainElement, kind, 'p.Future;', length: length),
+      ];
+      await _verifyReferences(element, expected);
+    }
+    {
+      ImportElement element = testLibraryElement.imports[1];
+      var expected = [
+        _expectId(mainElement, kind, 'p.Random', length: length),
+      ];
+      await _verifyReferences(element, expected);
+    }
+  }
+
   test_searchReferences_LabelElement() async {
     await _resolveTestUnit('''
 main() {
@@ -539,6 +661,88 @@
     await _verifyReferences(element, expected);
   }
 
+  test_searchReferences_private_declaredInDefiningUnit() async {
+    String p1 = _p('$testProject/part1.dart');
+    String p2 = _p('$testProject/part2.dart');
+    String p3 = _p('$testProject/part3.dart');
+    String code1 = 'part of lib; _C v1;';
+    String code2 = 'part of lib; _C v2;';
+    provider.newFile(p1, code1);
+    provider.newFile(p2, code2);
+    provider.newFile(p3, 'part of lib; int v3;');
+
+    driver.addFile(p1);
+    driver.addFile(p2);
+    driver.addFile(p3);
+
+    await _resolveTestUnit('''
+library lib;
+part 'part1.dart';
+part 'part2.dart';
+part 'part3.dart';
+class _C {}
+_C v;
+''');
+    ClassElement element = _findElementAtString('_C {}');
+    Element v = testUnitElement.topLevelVariables[0];
+    Element v1 = testLibraryElement.parts[0].topLevelVariables[0];
+    Element v2 = testLibraryElement.parts[1].topLevelVariables[0];
+    var expected = [
+      _expectId(v, SearchResultKind.REFERENCE, '_C v;', length: 2),
+      new ExpectedResult(
+          v1, SearchResultKind.REFERENCE, code1.indexOf('_C v1;'), 2),
+      new ExpectedResult(
+          v2, SearchResultKind.REFERENCE, code2.indexOf('_C v2;'), 2),
+    ];
+    await _verifyReferences(element, expected);
+  }
+
+  test_searchReferences_private_declaredInPart() async {
+    String p = _p('$testProject/lib.dart');
+    String p1 = _p('$testProject/part1.dart');
+    String p2 = _p('$testProject/part2.dart');
+
+    var code = '''
+library lib;
+part 'part1.dart';
+part 'part2.dart';
+_C v;
+''';
+    var code1 = '''
+part of lib;
+class _C {}
+_C v1;
+''';
+    String code2 = 'part of lib; _C v2;';
+
+    provider.newFile(p, code);
+    provider.newFile(p1, code1);
+    provider.newFile(p2, code2);
+
+    driver.addFile(p);
+    driver.addFile(p1);
+    driver.addFile(p2);
+
+    AnalysisResult result = await driver.getResult(p);
+    testUnit = result.unit;
+    testUnitElement = testUnit.element;
+    testLibraryElement = testUnitElement.library;
+
+    ClassElement element = testLibraryElement.parts[0].types[0];
+    Element v = testUnitElement.topLevelVariables[0];
+    Element v1 = testLibraryElement.parts[0].topLevelVariables[0];
+    Element v2 = testLibraryElement.parts[1].topLevelVariables[0];
+    var expected = [
+      new ExpectedResult(
+          v, SearchResultKind.REFERENCE, code.indexOf('_C v;'), 2),
+      new ExpectedResult(
+          v1, SearchResultKind.REFERENCE, code1.indexOf('_C v1;'), 2),
+      new ExpectedResult(
+          v2, SearchResultKind.REFERENCE, code2.indexOf('_C v2;'), 2),
+    ];
+    await _verifyReferences(element, expected);
+  }
+
   test_searchReferences_PropertyAccessorElement_getter() async {
     await _resolveTestUnit('''
 class A {
@@ -682,6 +886,25 @@
     await _verifyReferences(element, expected);
   }
 
+  test_searchSubtypes() async {
+    await _resolveTestUnit('''
+class T {}
+class A extends T {} // A
+class B = Object with T; // B
+class C implements T {} // C
+''');
+    ClassElement element = _findElement('T');
+    ClassElement a = _findElement('A');
+    ClassElement b = _findElement('B');
+    ClassElement c = _findElement('C');
+    var expected = [
+      _expectId(a, SearchResultKind.REFERENCE, 'T {} // A'),
+      _expectId(b, SearchResultKind.REFERENCE, 'T; // B'),
+      _expectId(c, SearchResultKind.REFERENCE, 'T {} // C'),
+    ];
+    await _verifyReferences(element, expected);
+  }
+
   ExpectedResult _expectId(
       Element enclosingElement, SearchResultKind kind, String search,
       {int length, bool isResolved: true, bool isQualified: false}) {
diff --git a/pkg/analyzer/test/src/dart/ast/utilities_test.dart b/pkg/analyzer/test/src/dart/ast/utilities_test.dart
index 5a18e5f..368c307 100644
--- a/pkg/analyzer/test/src/dart/ast/utilities_test.dart
+++ b/pkg/analyzer/test/src/dart/ast/utilities_test.dart
@@ -5,6 +5,7 @@
 library analyzer.test.src.dart.ast.utilities_test;
 
 import 'package:analyzer/dart/ast/ast.dart';
+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/type.dart';
@@ -437,9 +438,9 @@
 @reflectiveTest
 class ResolutionCopierTest extends EngineTestCase {
   void test_visitAdjacentStrings() {
-    AdjacentStrings createNode() => new AdjacentStrings([
-          new SimpleStringLiteral(null, 'hello'),
-          new SimpleStringLiteral(null, 'world')
+    AdjacentStrings createNode() => astFactory.adjacentStrings([
+          astFactory.simpleStringLiteral(null, 'hello'),
+          astFactory.simpleStringLiteral(null, 'world')
         ]);
 
     AdjacentStrings fromNode = createNode();
@@ -1555,13 +1556,13 @@
   void test_visitComment() {
     _assertSource(
         "",
-        Comment.createBlockComment(
+        astFactory.blockComment(
             <Token>[TokenFactory.tokenFromString("/* comment */")]));
   }
 
   void test_visitCommentReference() {
     _assertSource(
-        "", new CommentReference(null, AstTestFactory.identifier3("a")));
+        "", astFactory.commentReference(null, AstTestFactory.identifier3("a")));
   }
 
   void test_visitCompilationUnit_declaration() {
@@ -1947,7 +1948,7 @@
   void test_visitFieldFormalParameter_functionTyped_typeParameters() {
     _assertSource(
         "A this.a<E, F>(b)",
-        new FieldFormalParameter(
+        astFactory.fieldFormalParameter(
             null,
             null,
             null,
@@ -1989,7 +1990,7 @@
   void test_visitForEachStatement_variable() {
     _assertSource(
         "for (a in b) {}",
-        new ForEachStatement.withReference(
+        astFactory.forEachStatementWithReference(
             null,
             TokenFactory.tokenFromKeyword(Keyword.FOR),
             TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
@@ -2003,7 +2004,7 @@
   void test_visitForEachStatement_variable_await() {
     _assertSource(
         "await for (a in b) {}",
-        new ForEachStatement.withReference(
+        astFactory.forEachStatementWithReference(
             TokenFactory.tokenFromString("await"),
             TokenFactory.tokenFromKeyword(Keyword.FOR),
             TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
@@ -2305,7 +2306,7 @@
     FunctionDeclaration f = AstTestFactory.functionDeclaration(
         null, null, "f", AstTestFactory.functionExpression());
     FunctionDeclarationStatement fStatement =
-        new FunctionDeclarationStatement(f);
+        astFactory.functionDeclarationStatement(f);
     _assertSource(
         "main() {f() {} 42;}",
         AstTestFactory.functionDeclaration(
@@ -2328,7 +2329,7 @@
         AstTestFactory.functionExpression2(AstTestFactory.formalParameterList(),
             AstTestFactory.expressionFunctionBody(AstTestFactory.integer(1))));
     FunctionDeclarationStatement fStatement =
-        new FunctionDeclarationStatement(f);
+        astFactory.functionDeclarationStatement(f);
     _assertSource(
         "main() {f() => 1; 2;}",
         AstTestFactory.functionDeclaration(
@@ -2464,7 +2465,7 @@
   void test_visitFunctionTypedFormalParameter_typeParameters() {
     _assertSource(
         "T f<E>()",
-        new FunctionTypedFormalParameter(
+        astFactory.functionTypedFormalParameter(
             null,
             null,
             AstTestFactory.typeName4("T"),
@@ -3885,13 +3886,13 @@
   void test_visitComment() {
     _assertSource(
         "",
-        Comment.createBlockComment(
+        astFactory.blockComment(
             <Token>[TokenFactory.tokenFromString("/* comment */")]));
   }
 
   void test_visitCommentReference() {
     _assertSource(
-        "", new CommentReference(null, AstTestFactory.identifier3("a")));
+        "", astFactory.commentReference(null, AstTestFactory.identifier3("a")));
   }
 
   void test_visitCompilationUnit_declaration() {
@@ -4277,7 +4278,7 @@
   void test_visitFieldFormalParameter_functionTyped_typeParameters() {
     _assertSource(
         "A this.a<E, F>(b)",
-        new FieldFormalParameter(
+        astFactory.fieldFormalParameter(
             null,
             null,
             null,
@@ -4319,7 +4320,7 @@
   void test_visitForEachStatement_variable() {
     _assertSource(
         "for (a in b) {}",
-        new ForEachStatement.withReference(
+        astFactory.forEachStatementWithReference(
             null,
             TokenFactory.tokenFromKeyword(Keyword.FOR),
             TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
@@ -4333,7 +4334,7 @@
   void test_visitForEachStatement_variable_await() {
     _assertSource(
         "await for (a in b) {}",
-        new ForEachStatement.withReference(
+        astFactory.forEachStatementWithReference(
             TokenFactory.tokenFromString("await"),
             TokenFactory.tokenFromKeyword(Keyword.FOR),
             TokenFactory.tokenFromType(TokenType.OPEN_PAREN),
@@ -4635,7 +4636,7 @@
     FunctionDeclaration f = AstTestFactory.functionDeclaration(
         null, null, "f", AstTestFactory.functionExpression());
     FunctionDeclarationStatement fStatement =
-        new FunctionDeclarationStatement(f);
+        astFactory.functionDeclarationStatement(f);
     _assertSource(
         "main() {f() {} 42;}",
         AstTestFactory.functionDeclaration(
@@ -4658,7 +4659,7 @@
         AstTestFactory.functionExpression2(AstTestFactory.formalParameterList(),
             AstTestFactory.expressionFunctionBody(AstTestFactory.integer(1))));
     FunctionDeclarationStatement fStatement =
-        new FunctionDeclarationStatement(f);
+        astFactory.functionDeclarationStatement(f);
     _assertSource(
         "main() {f() => 1; 2;}",
         AstTestFactory.functionDeclaration(
@@ -4794,7 +4795,7 @@
   void test_visitFunctionTypedFormalParameter_typeParameters() {
     _assertSource(
         "T f<E>()",
-        new FunctionTypedFormalParameter(
+        astFactory.functionTypedFormalParameter(
             null,
             null,
             AstTestFactory.typeName4("T"),
diff --git a/pkg/analyzer/test/src/dart/constant/utilities_test.dart b/pkg/analyzer/test/src/dart/constant/utilities_test.dart
index 9920600..bf382f1 100644
--- a/pkg/analyzer/test/src/dart/constant/utilities_test.dart
+++ b/pkg/analyzer/test/src/dart/constant/utilities_test.dart
@@ -5,6 +5,7 @@
 library analyzer.test.src.dart.constant.utilities_test;
 
 import 'package:analyzer/dart/ast/ast.dart';
+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/src/dart/ast/token.dart';
@@ -65,7 +66,7 @@
     // Analyzer ignores annotations on enum constant declarations.
     Annotation annotation = AstTestFactory.annotation2(
         AstTestFactory.identifier3('A'), null, AstTestFactory.argumentList());
-    _node = new EnumConstantDeclaration(
+    _node = astFactory.enumConstantDeclaration(
         null, <Annotation>[annotation], AstTestFactory.identifier3('C'));
     expect(_findConstants(), isEmpty);
   }
diff --git a/pkg/analyzer/test/src/summary/resynthesize_common.dart b/pkg/analyzer/test/src/summary/resynthesize_common.dart
index ddff695..e654efd 100644
--- a/pkg/analyzer/test/src/summary/resynthesize_common.dart
+++ b/pkg/analyzer/test/src/summary/resynthesize_common.dart
@@ -4674,6 +4674,13 @@
     checkLibrary("import 'foo.dart';", allowErrors: true);
   }
 
+  test_unresolved_import_deferred() {
+    allowMissingFiles = true;
+    LibraryElementImpl library =
+        checkLibrary("import 'missing.dart' deferred as p;");
+    expect(library.imports[0].importedLibrary.loadLibraryFunction, isNotNull);
+  }
+
   test_unresolved_part() {
     allowMissingFiles = true;
     checkLibrary("part 'foo.dart';", allowErrors: true);
diff --git a/pkg/analyzer/test/src/summary/summarize_ast_test.dart b/pkg/analyzer/test/src/summary/summarize_ast_test.dart
index e0083e0..fed8019 100644
--- a/pkg/analyzer/test/src/summary/summarize_ast_test.dart
+++ b/pkg/analyzer/test/src/summary/summarize_ast_test.dart
@@ -268,8 +268,8 @@
       {String path: '/test.dart', String uri}) {
     uri ??= absUri(path);
     Uri testDartUri = Uri.parse(uri);
-    CompilationUnit unit = _parseText(text);
-    UnlinkedUnitBuilder unlinkedDefiningUnit = serializeAstUnlinked(unit);
+    UnlinkedUnitBuilder unlinkedDefiningUnit =
+      createUnlinkedSummary(testDartUri, text);
     _filesToLink.uriToUnit[testDartUri.toString()] = unlinkedDefiningUnit;
     LinkerInputs linkerInputs = new LinkerInputs(
         allowMissingFiles,
@@ -283,6 +283,9 @@
     return linkerInputs;
   }
 
+  UnlinkedUnitBuilder createUnlinkedSummary(Uri uri, String text) =>
+      serializeAstUnlinked(_parseText(text));
+
   /**
    * Link together the given file, along with any other files passed to
    * [addNamedSource], to form a package bundle.  Reset the state of the buffers
diff --git a/pkg/analyzer/test/src/summary/summary_common.dart b/pkg/analyzer/test/src/summary/summary_common.dart
index fd93301..7f362ae 100644
--- a/pkg/analyzer/test/src/summary/summary_common.dart
+++ b/pkg/analyzer/test/src/summary/summary_common.dart
@@ -163,6 +163,13 @@
   bool get strongMode;
 
   /**
+   * Whether the parts of the IDL marked `@informative` are expected to be
+   * included in the generated summary; if `false`, these parts of the IDL won't
+   * be checked.
+   */
+  bool get includeInformative => true;
+
+  /**
    * Get access to the unlinked compilation unit summaries that result from
    * serializing and deserializing the library under test.
    */
@@ -180,7 +187,7 @@
    */
   void checkAnnotationA(List<UnlinkedExpr> annotations) {
     expect(annotations, hasLength(1));
-    _assertUnlinkedConst(annotations[0], operators: [
+    assertUnlinkedConst(annotations[0], operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'a',
@@ -1116,6 +1123,7 @@
   }
 
   test_class_alias_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -1194,6 +1202,7 @@
   }
 
   test_class_codeRange() {
+    if (!includeInformative) return;
     UnlinkedClass cls = serializeClassText(' class C {}');
     _assertCodeRange(cls.codeRange, 1, 10);
   }
@@ -1282,6 +1291,7 @@
   }
 
   test_class_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -1294,6 +1304,7 @@
   }
 
   test_class_documented_with_references() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -1309,6 +1320,7 @@
   }
 
   test_class_documented_with_with_windows_line_endings() {
+    if (!includeInformative) return;
     String text = '/**\r\n * Docs\r\n */\r\nclass C {}';
     UnlinkedClass cls = serializeClassText(text);
     expect(cls.documentationComment, isNotNull);
@@ -1359,7 +1371,9 @@
     var classText = 'class C {}';
     UnlinkedClass cls = serializeClassText(classText);
     expect(cls.name, 'C');
-    expect(cls.nameOffset, classText.indexOf('C'));
+    if (includeInformative) {
+      expect(cls.nameOffset, classText.indexOf('C'));
+    }
   }
 
   test_class_no_flags() {
@@ -1449,7 +1463,9 @@
     UnlinkedClass cls = serializeClassText(text);
     expect(cls.typeParameters, hasLength(1));
     expect(cls.typeParameters[0].name, 'T');
-    expect(cls.typeParameters[0].nameOffset, text.indexOf('T'));
+    if (includeInformative) {
+      expect(cls.typeParameters[0].nameOffset, text.indexOf('T'));
+    }
     expect(cls.typeParameters[0].bound, isNull);
     expect(unlinkedUnits[0].publicNamespace.names[0].numTypeParameters, 1);
   }
@@ -1545,7 +1561,7 @@
 
   test_constExpr_binary_add() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 + 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.add
@@ -1558,7 +1574,7 @@
   test_constExpr_binary_and() {
     UnlinkedVariable variable =
         serializeVariableText('const v = true && false;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushTrue,
       UnlinkedExprOperation.pushFalse,
       UnlinkedExprOperation.and
@@ -1567,7 +1583,7 @@
 
   test_constExpr_binary_bitAnd() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 & 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.bitAnd
@@ -1579,7 +1595,7 @@
 
   test_constExpr_binary_bitOr() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 | 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.bitOr
@@ -1591,7 +1607,7 @@
 
   test_constExpr_binary_bitShiftLeft() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 << 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.bitShiftLeft
@@ -1603,7 +1619,7 @@
 
   test_constExpr_binary_bitShiftRight() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 >> 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.bitShiftRight
@@ -1615,7 +1631,7 @@
 
   test_constExpr_binary_bitXor() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 ^ 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.bitXor
@@ -1627,7 +1643,7 @@
 
   test_constExpr_binary_divide() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 / 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.divide
@@ -1639,7 +1655,7 @@
 
   test_constExpr_binary_equal() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 == 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.equal
@@ -1651,7 +1667,7 @@
 
   test_constExpr_binary_equal_not() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 != 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.notEqual
@@ -1663,7 +1679,7 @@
 
   test_constExpr_binary_floorDivide() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 ~/ 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.floorDivide
@@ -1675,7 +1691,7 @@
 
   test_constExpr_binary_greater() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 > 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.greater
@@ -1687,7 +1703,7 @@
 
   test_constExpr_binary_greaterEqual() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 >= 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.greaterEqual
@@ -1699,7 +1715,7 @@
 
   test_constExpr_binary_less() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 < 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.less
@@ -1711,7 +1727,7 @@
 
   test_constExpr_binary_lessEqual() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 <= 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.lessEqual
@@ -1723,7 +1739,7 @@
 
   test_constExpr_binary_modulo() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 % 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.modulo
@@ -1735,7 +1751,7 @@
 
   test_constExpr_binary_multiply() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 * 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.multiply
@@ -1748,7 +1764,7 @@
   test_constExpr_binary_or() {
     UnlinkedVariable variable =
         serializeVariableText('const v = false || true;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushFalse,
       UnlinkedExprOperation.pushTrue,
       UnlinkedExprOperation.or
@@ -1757,7 +1773,7 @@
 
   test_constExpr_binary_qq() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 ?? 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.ifNull
@@ -1769,7 +1785,7 @@
 
   test_constExpr_binary_subtract() {
     UnlinkedVariable variable = serializeVariableText('const v = 1 - 2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.subtract
@@ -1792,7 +1808,7 @@
 }
 ''';
     UnlinkedClass cls = serializeClassText(text, allowErrors: true);
-    _assertUnlinkedConst(cls.executables[0].constantInitializers[0].expression,
+    assertUnlinkedConst(cls.executables[0].constantInitializers[0].expression,
         operators: [
           UnlinkedExprOperation.pushReference
         ],
@@ -1809,7 +1825,7 @@
   test_constExpr_conditional() {
     UnlinkedVariable variable =
         serializeVariableText('const v = true ? 1 : 2;', allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushTrue,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
@@ -1828,7 +1844,7 @@
   const C(a) : b = a;
 }
 ''');
-    _assertUnlinkedConst(cls.executables[0].constantInitializers[0].expression,
+    assertUnlinkedConst(cls.executables[0].constantInitializers[0].expression,
         operators: [UnlinkedExprOperation.pushParameter], strings: ['a']);
   }
 
@@ -1839,7 +1855,7 @@
   const C(T) : x = T;
 }
 ''');
-    _assertUnlinkedConst(cls.executables[0].constantInitializers[0].expression,
+    assertUnlinkedConst(cls.executables[0].constantInitializers[0].expression,
         operators: [UnlinkedExprOperation.pushParameter], strings: ['T']);
   }
 
@@ -1851,7 +1867,7 @@
 import 'dart:async';
 const v = (f) async => await f;
 ''');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushParameter,
@@ -1871,7 +1887,7 @@
 const v = foo(5, () => 42);
 foo(a, b) {}
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -1900,7 +1916,7 @@
 const v = foo(5, () => 42, () => 43);
 foo(a, b, c) {}
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -1935,11 +1951,11 @@
 }
 ''').executables[0];
     expect(executable.localFunctions, hasLength(2));
-    _assertUnlinkedConst(executable.constantInitializers[0].expression,
+    assertUnlinkedConst(executable.constantInitializers[0].expression,
         isValidConst: false,
         operators: [UnlinkedExprOperation.pushLocalFunctionReference],
         ints: [0, 0]);
-    _assertUnlinkedConst(executable.constantInitializers[1].expression,
+    assertUnlinkedConst(executable.constantInitializers[1].expression,
         isValidConst: false,
         operators: [UnlinkedExprOperation.pushLocalFunctionReference],
         ints: [0, 1]);
@@ -1952,7 +1968,7 @@
 }
 const v = const C<int, String>.named();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -1984,7 +2000,7 @@
 import 'a.dart';
 const v = const C<int, String>.named();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2018,7 +2034,7 @@
 import 'a.dart' as p;
 const v = const p.C<int, String>.named();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2048,7 +2064,7 @@
 }
 const v = const C<int, String>();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2077,7 +2093,7 @@
 import 'a.dart';
 const v = const C<int, String>();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2106,7 +2122,7 @@
 import 'a.dart' as p;
 const v = const p.C<int, String>();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2133,7 +2149,7 @@
 }
 const v = const C.named();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2159,7 +2175,7 @@
 import 'a.dart';
 const v = const C.named();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2186,7 +2202,7 @@
 import 'a.dart' as p;
 const v = const p.C.named();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2213,7 +2229,7 @@
     // Ints: ^pointer 3 4
     // Doubles: ^pointer
     // Strings: ^pointer 'e' 'g' 'f' ''
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushDouble,
@@ -2255,7 +2271,7 @@
 import 'a.dart';
 const v = const C();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2278,7 +2294,7 @@
 import 'a.dart' as p;
 const v = const p.C();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2299,7 +2315,7 @@
 const v = const C.foo();
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2319,7 +2335,7 @@
 const v = const C.foo();
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2346,7 +2362,7 @@
 const v = const p.C.foo();
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2370,7 +2386,7 @@
 const v = const p.C.foo();
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2391,7 +2407,7 @@
 const v = const Foo();
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -2405,7 +2421,7 @@
   test_constExpr_invokeMethodRef_identical() {
     UnlinkedVariable variable =
         serializeVariableText('const v = identical(42, null);');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushNull,
       UnlinkedExprOperation.invokeMethodRef
@@ -2429,7 +2445,7 @@
 }
 const int v = C.length;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'length',
@@ -2452,7 +2468,7 @@
 import 'a.dart' as p;
 const int v = p.C.length;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'length',
@@ -2470,7 +2486,7 @@
 const String a = 'aaa';
 const int v = a.length;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'length',
@@ -2490,7 +2506,7 @@
 }
 const int v = C.F.length;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'length',
@@ -2513,7 +2529,7 @@
 import 'a.dart';
 const int v = a.length;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'length',
@@ -2537,7 +2553,7 @@
 import 'a.dart' as p;
 const int v = p.a.length;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'length',
@@ -2555,7 +2571,7 @@
   test_constExpr_length_parenthesizedBinaryTarget() {
     UnlinkedVariable variable =
         serializeVariableText('const v = ("abc" + "edf").length;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.add,
@@ -2570,7 +2586,7 @@
   test_constExpr_length_parenthesizedStringTarget() {
     UnlinkedVariable variable =
         serializeVariableText('const v = ("abc").length;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.extractProperty
     ], strings: [
@@ -2582,7 +2598,7 @@
   test_constExpr_length_stringLiteralTarget() {
     UnlinkedVariable variable =
         serializeVariableText('const v = "abc".length;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.extractProperty
     ], strings: [
@@ -2593,14 +2609,14 @@
 
   test_constExpr_makeSymbol() {
     UnlinkedVariable variable = serializeVariableText('const v = #a.bb.ccc;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.makeSymbol], strings: ['a.bb.ccc']);
   }
 
   test_constExpr_makeTypedList() {
     UnlinkedVariable variable =
         serializeVariableText('const v = const <int>[11, 22, 33];');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
@@ -2619,7 +2635,7 @@
   test_constExpr_makeTypedList_dynamic() {
     UnlinkedVariable variable =
         serializeVariableText('const v = const <dynamic>[11, 22, 33];');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
@@ -2637,7 +2653,7 @@
   test_constExpr_makeTypedMap() {
     UnlinkedVariable variable = serializeVariableText(
         'const v = const <int, String>{11: "aaa", 22: "bbb", 33: "ccc"};');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.pushInt,
@@ -2665,7 +2681,7 @@
   test_constExpr_makeTypedMap_dynamic() {
     UnlinkedVariable variable = serializeVariableText(
         'const v = const <dynamic, dynamic>{11: "aaa", 22: "bbb", 33: "ccc"};');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.pushInt,
@@ -2691,7 +2707,7 @@
   test_constExpr_makeUntypedList() {
     UnlinkedVariable variable =
         serializeVariableText('const v = const [11, 22, 33];');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
@@ -2707,7 +2723,7 @@
   test_constExpr_makeUntypedMap() {
     UnlinkedVariable variable = serializeVariableText(
         'const v = const {11: "aaa", 22: "bbb", 33: "ccc"};');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.pushInt,
@@ -2729,7 +2745,7 @@
 
   test_constExpr_parenthesized() {
     UnlinkedVariable variable = serializeVariableText('const v = (1 + 2) * 3;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.add,
@@ -2744,7 +2760,7 @@
 
   test_constExpr_prefix_complement() {
     UnlinkedVariable variable = serializeVariableText('const v = ~2;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.complement
     ], ints: [
@@ -2754,7 +2770,7 @@
 
   test_constExpr_prefix_negate() {
     UnlinkedVariable variable = serializeVariableText('const v = -(2);');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.negate
     ], ints: [
@@ -2764,31 +2780,31 @@
 
   test_constExpr_prefix_not() {
     UnlinkedVariable variable = serializeVariableText('const v = !true;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushTrue, UnlinkedExprOperation.not]);
   }
 
   test_constExpr_pushDouble() {
     UnlinkedVariable variable = serializeVariableText('const v = 123.4567;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushDouble], doubles: [123.4567]);
   }
 
   test_constExpr_pushFalse() {
     UnlinkedVariable variable = serializeVariableText('const v = false;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushFalse]);
   }
 
   test_constExpr_pushInt() {
     UnlinkedVariable variable = serializeVariableText('const v = 1;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [1]);
   }
 
   test_constExpr_pushInt_max() {
     UnlinkedVariable variable = serializeVariableText('const v = 0xFFFFFFFF;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
     ], ints: [
       0xFFFFFFFF
@@ -2797,7 +2813,7 @@
 
   test_constExpr_pushInt_negative() {
     UnlinkedVariable variable = serializeVariableText('const v = -5;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.negate
     ], ints: [
@@ -2808,14 +2824,14 @@
   test_constExpr_pushLongInt() {
     UnlinkedVariable variable =
         serializeVariableText('const v = 0xA123456789ABCDEF012345678;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushLongInt],
         ints: [4, 0xA, 0x12345678, 0x9ABCDEF0, 0x12345678]);
   }
 
   test_constExpr_pushLongInt_min2() {
     UnlinkedVariable variable = serializeVariableText('const v = 0x100000000;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushLongInt
     ], ints: [
       2,
@@ -2827,7 +2843,7 @@
   test_constExpr_pushLongInt_min3() {
     UnlinkedVariable variable =
         serializeVariableText('const v = 0x10000000000000000;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushLongInt
     ], ints: [
       3,
@@ -2839,7 +2855,7 @@
 
   test_constExpr_pushNull() {
     UnlinkedVariable variable = serializeVariableText('const v = null;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushNull]);
   }
 
@@ -2848,7 +2864,7 @@
 class C {}
 const v = C;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'C',
@@ -2861,7 +2877,7 @@
 enum C {V1, V2, V3}
 const v = C;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'C',
@@ -2874,7 +2890,7 @@
 enum C {V1, V2, V3}
 const v = C.V1;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'V1',
@@ -2895,7 +2911,7 @@
 import 'a.dart';
 const v = C.V1;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'V1',
@@ -2912,7 +2928,7 @@
 enum C {V1, V2, V3}
 const v = C.values;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'values',
@@ -2933,7 +2949,7 @@
 import 'a.dart';
 const v = C.values;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'values',
@@ -2952,7 +2968,7 @@
 }
 const v = C.F;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'F',
@@ -2975,7 +2991,7 @@
 import 'a.dart';
 const v = C.F;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'F',
@@ -2999,7 +3015,7 @@
 import 'a.dart' as p;
 const v = p.C.F;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'F',
@@ -3019,7 +3035,7 @@
   static const b = null;
 }
 ''').fields[0];
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'b',
@@ -3037,7 +3053,7 @@
 }
 const v = C.x;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'x',
@@ -3060,7 +3076,7 @@
 import 'a.dart';
 const v = C.x;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'x',
@@ -3084,7 +3100,7 @@
 import 'a.dart' as p;
 const v = p.C.x;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'x',
@@ -3104,7 +3120,7 @@
 }
 const v = C.m;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'm',
@@ -3127,7 +3143,7 @@
 import 'a.dart';
 const v = C.m;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'm',
@@ -3151,7 +3167,7 @@
 import 'a.dart' as p;
 const v = p.C.m;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'm',
@@ -3171,7 +3187,7 @@
   static m() {}
 }
 ''').fields[0];
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'm',
@@ -3187,7 +3203,7 @@
 f() {}
 const v = f;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'f',
@@ -3205,7 +3221,7 @@
 import 'a.dart';
 const v = f;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, absUri('/a.dart'), 'a.dart', 'f',
@@ -3223,7 +3239,7 @@
 import 'a.dart' as p;
 const v = p.f;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, absUri('/a.dart'), 'a.dart', 'f',
@@ -3239,7 +3255,7 @@
 int get x => null;
 const v = x;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'x',
@@ -3253,7 +3269,7 @@
 import 'a.dart';
 const v = x;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, absUri('/a.dart'), 'a.dart', 'x',
@@ -3267,7 +3283,7 @@
 import 'a.dart' as p;
 const v = p.x;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, absUri('/a.dart'), 'a.dart', 'x',
@@ -3281,7 +3297,7 @@
 const int a = 1;
 const v = a;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'a',
@@ -3295,7 +3311,7 @@
 import 'a.dart';
 const v = a;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, absUri('/a.dart'), 'a.dart', 'a',
@@ -3309,7 +3325,7 @@
 import 'a.dart' as p;
 const v = p.a;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) {
@@ -3328,7 +3344,7 @@
 ''';
     UnlinkedVariable variable =
         serializeClassText(text, allowErrors: true).fields[0];
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) {
@@ -3343,7 +3359,7 @@
 const v = foo;
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'foo',
@@ -3358,7 +3374,7 @@
 const v = C.foo;
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'foo',
@@ -3381,7 +3397,7 @@
 const v = p.C.foo;
 ''',
         allowErrors: true);
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'foo',
@@ -3397,14 +3413,14 @@
   test_constExpr_pushString_adjacent() {
     UnlinkedVariable variable =
         serializeVariableText('const v = "aaa" "b" "ccc";');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushString], strings: ['aaabccc']);
   }
 
   test_constExpr_pushString_adjacent_interpolation() {
     UnlinkedVariable variable =
         serializeVariableText(r'const v = "aaa" "bb ${42} bbb" "cccc";');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.pushInt,
@@ -3427,7 +3443,7 @@
   test_constExpr_pushString_interpolation() {
     UnlinkedVariable variable =
         serializeVariableText(r'const v = "aaa ${42} bbb";');
-    _assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(variable.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushString,
       UnlinkedExprOperation.pushInt,
       UnlinkedExprOperation.pushString,
@@ -3443,13 +3459,13 @@
 
   test_constExpr_pushString_simple() {
     UnlinkedVariable variable = serializeVariableText('const v = "abc";');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushString], strings: ['abc']);
   }
 
   test_constExpr_pushTrue() {
     UnlinkedVariable variable = serializeVariableText('const v = true;');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushTrue]);
   }
 
@@ -3462,14 +3478,19 @@
     expect(executable.isAsynchronous, isFalse);
     expect(executable.isExternal, isFalse);
     expect(executable.isGenerator, isFalse);
-    expect(executable.nameOffset, text.indexOf('C();'));
-    expect(executable.periodOffset, 0);
-    expect(executable.nameEnd, 0);
+    if (includeInformative) {
+      expect(executable.nameOffset, text.indexOf('C();'));
+      expect(executable.periodOffset, 0);
+      expect(executable.nameEnd, 0);
+    }
     expect(executable.isRedirectedConstructor, isFalse);
     expect(executable.redirectedConstructor, isNull);
     expect(executable.redirectedConstructorName, isEmpty);
-    expect(executable.visibleOffset, 0);
-    expect(executable.visibleLength, 0);
+
+    if (includeInformative) {
+      expect(executable.visibleOffset, 0);
+      expect(executable.visibleLength, 0);
+    }
   }
 
   test_constructor_anonymous() {
@@ -3494,6 +3515,7 @@
   }
 
   test_constructor_documented() {
+    if (!includeInformative) return;
     String text = '''
 class C {
   /**
@@ -3541,7 +3563,7 @@
         executable.constantInitializers[0];
     expect(initializer.kind, UnlinkedConstructorInitializerKind.field);
     expect(initializer.name, 'x');
-    _assertUnlinkedConst(initializer.expression,
+    assertUnlinkedConst(initializer.expression,
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
     expect(initializer.arguments, isEmpty);
   }
@@ -3559,7 +3581,7 @@
         executable.constantInitializers[0];
     expect(initializer.kind, UnlinkedConstructorInitializerKind.field);
     expect(initializer.name, 'x');
-    _assertUnlinkedConst(initializer.expression,
+    assertUnlinkedConst(initializer.expression,
         operators: [UnlinkedExprOperation.pushParameter], strings: ['p']);
     expect(initializer.arguments, isEmpty);
   }
@@ -3593,7 +3615,7 @@
     expect(initializer.name, 'aaa');
     expect(initializer.expression, isNull);
     expect(initializer.arguments, hasLength(1));
-    _assertUnlinkedConst(initializer.arguments[0],
+    assertUnlinkedConst(initializer.arguments[0],
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
   }
 
@@ -3615,11 +3637,11 @@
     expect(initializer.name, '');
     expect(initializer.expression, isNull);
     expect(initializer.arguments, hasLength(3));
-    _assertUnlinkedConst(initializer.arguments[0],
+    assertUnlinkedConst(initializer.arguments[0],
         operators: [UnlinkedExprOperation.pushInt], ints: [1]);
-    _assertUnlinkedConst(initializer.arguments[1],
+    assertUnlinkedConst(initializer.arguments[1],
         operators: [UnlinkedExprOperation.pushInt], ints: [2]);
-    _assertUnlinkedConst(initializer.arguments[2],
+    assertUnlinkedConst(initializer.arguments[2],
         operators: [UnlinkedExprOperation.pushInt], ints: [3]);
     expect(initializer.argumentNames, ['b', 'c']);
   }
@@ -3642,7 +3664,7 @@
     expect(initializer.name, '');
     expect(initializer.expression, isNull);
     expect(initializer.arguments, hasLength(1));
-    _assertUnlinkedConst(initializer.arguments[0],
+    assertUnlinkedConst(initializer.arguments[0],
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
   }
 
@@ -3661,9 +3683,9 @@
     expect(initializer.name, 'named');
     expect(initializer.expression, isNull);
     expect(initializer.arguments, hasLength(2));
-    _assertUnlinkedConst(initializer.arguments[0],
+    assertUnlinkedConst(initializer.arguments[0],
         operators: [UnlinkedExprOperation.pushInt], ints: [1]);
-    _assertUnlinkedConst(initializer.arguments[1],
+    assertUnlinkedConst(initializer.arguments[1],
         operators: [UnlinkedExprOperation.pushString], strings: ['bbb']);
   }
 
@@ -3682,11 +3704,11 @@
     expect(initializer.name, 'named');
     expect(initializer.expression, isNull);
     expect(initializer.arguments, hasLength(3));
-    _assertUnlinkedConst(initializer.arguments[0],
+    assertUnlinkedConst(initializer.arguments[0],
         operators: [UnlinkedExprOperation.pushInt], ints: [1]);
-    _assertUnlinkedConst(initializer.arguments[1],
+    assertUnlinkedConst(initializer.arguments[1],
         operators: [UnlinkedExprOperation.pushInt], ints: [2]);
-    _assertUnlinkedConst(initializer.arguments[2],
+    assertUnlinkedConst(initializer.arguments[2],
         operators: [UnlinkedExprOperation.pushInt], ints: [3]);
     expect(initializer.argumentNames, ['b', 'c']);
   }
@@ -3706,9 +3728,9 @@
     expect(initializer.name, '');
     expect(initializer.expression, isNull);
     expect(initializer.arguments, hasLength(2));
-    _assertUnlinkedConst(initializer.arguments[0],
+    assertUnlinkedConst(initializer.arguments[0],
         operators: [UnlinkedExprOperation.pushInt], ints: [1]);
-    _assertUnlinkedConst(initializer.arguments[1],
+    assertUnlinkedConst(initializer.arguments[1],
         operators: [UnlinkedExprOperation.pushString], strings: ['bbb']);
   }
 
@@ -3793,7 +3815,7 @@
     expect(param.isFunctionTyped, isTrue);
     expect(param.kind, UnlinkedParamKind.positional);
     expect(param.defaultValueCode, 'foo');
-    _assertUnlinkedConst(param.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(param.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'foo',
@@ -3837,8 +3859,10 @@
     expect(parameter.kind, UnlinkedParamKind.named);
     expect(parameter.initializer, isNotNull);
     expect(parameter.defaultValueCode, '42');
-    _assertCodeRange(parameter.codeRange, 13, 10);
-    _assertUnlinkedConst(parameter.initializer.bodyExpr,
+    if (includeInformative) {
+      _assertCodeRange(parameter.codeRange, 13, 10);
+    }
+    assertUnlinkedConst(parameter.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
   }
 
@@ -3869,8 +3893,10 @@
     expect(parameter.kind, UnlinkedParamKind.positional);
     expect(parameter.initializer, isNotNull);
     expect(parameter.defaultValueCode, '42');
-    _assertCodeRange(parameter.codeRange, 13, 11);
-    _assertUnlinkedConst(parameter.initializer.bodyExpr,
+    if (includeInformative) {
+      _assertCodeRange(parameter.codeRange, 13, 11);
+    }
+    assertUnlinkedConst(parameter.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
   }
 
@@ -3902,7 +3928,7 @@
     UnlinkedParam param = executable.parameters[0];
     expect(param.kind, UnlinkedParamKind.positional);
     expect(param.defaultValueCode, '42');
-    _assertUnlinkedConst(param.initializer.bodyExpr,
+    assertUnlinkedConst(param.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
   }
 
@@ -3911,10 +3937,12 @@
     UnlinkedExecutable executable = findExecutable('foo',
         executables: serializeClassText(text).executables);
     expect(executable.name, 'foo');
-    expect(executable.nameOffset, text.indexOf('foo'));
-    expect(executable.periodOffset, text.indexOf('.foo'));
-    expect(executable.nameEnd, text.indexOf('()'));
-    _assertCodeRange(executable.codeRange, 10, 8);
+    if (includeInformative) {
+      expect(executable.nameOffset, text.indexOf('foo'));
+      expect(executable.periodOffset, text.indexOf('.foo'));
+      expect(executable.nameEnd, text.indexOf('()'));
+      _assertCodeRange(executable.codeRange, 10, 8);
+    }
   }
 
   test_constructor_non_const() {
@@ -5012,11 +5040,15 @@
     String text = 'enum E { v1 }';
     UnlinkedEnum e = serializeEnumText(text);
     expect(e.name, 'E');
-    expect(e.nameOffset, text.indexOf('E'));
+    if (includeInformative) {
+      expect(e.nameOffset, text.indexOf('E'));
+    }
     expect(e.values, hasLength(1));
     expect(e.values[0].name, 'v1');
-    expect(e.values[0].nameOffset, text.indexOf('v1'));
-    _assertCodeRange(e.codeRange, 0, 13);
+    if (includeInformative) {
+      expect(e.values[0].nameOffset, text.indexOf('v1'));
+      _assertCodeRange(e.codeRange, 0, 13);
+    }
     expect(unlinkedUnits[0].publicNamespace.names, hasLength(1));
     expect(unlinkedUnits[0].publicNamespace.names[0].kind,
         ReferenceKind.classOrEnum);
@@ -5038,6 +5070,7 @@
   }
 
   test_enum_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -5062,6 +5095,7 @@
   }
 
   test_enum_value_documented() {
+    if (!includeInformative) return;
     String text = '''
 enum E {
   /**
@@ -5101,9 +5135,11 @@
     expect(executable.isAsynchronous, isFalse);
     expect(executable.isExternal, isFalse);
     expect(executable.isGenerator, isFalse);
-    expect(executable.nameOffset, text.indexOf('f'));
-    expect(executable.visibleOffset, 0);
-    expect(executable.visibleLength, 0);
+    if (includeInformative) {
+      expect(executable.nameOffset, text.indexOf('f'));
+      expect(executable.visibleOffset, 0);
+      expect(executable.visibleLength, 0);
+    }
     expect(unlinkedUnits[0].publicNamespace.names, hasLength(1));
     expect(unlinkedUnits[0].publicNamespace.names[0].kind,
         ReferenceKind.topLevelFunction);
@@ -5153,7 +5189,9 @@
     expect(executable.isAsynchronous, isFalse);
     expect(executable.isExternal, isFalse);
     expect(executable.isGenerator, isFalse);
-    expect(executable.nameOffset, text.indexOf('f'));
+    if (includeInformative) {
+      expect(executable.nameOffset, text.indexOf('f'));
+    }
     expect(findVariable('f'), isNull);
     expect(findExecutable('f='), isNull);
     expect(unlinkedUnits[0].publicNamespace.names, hasLength(1));
@@ -5518,9 +5556,11 @@
     expect(executable.isAsynchronous, isFalse);
     expect(executable.isExternal, isFalse);
     expect(executable.isGenerator, isFalse);
-    expect(executable.visibleOffset, 0);
-    expect(executable.visibleLength, 0);
-    _assertCodeRange(executable.codeRange, 10, 6);
+    if (includeInformative) {
+      expect(executable.visibleOffset, 0);
+      expect(executable.visibleLength, 0);
+      _assertCodeRange(executable.codeRange, 10, 6);
+    }
   }
 
   test_executable_member_function_async() {
@@ -5571,7 +5611,9 @@
     expect(executable.isExternal, isFalse);
     expect(executable.isGenerator, isFalse);
     expect(executable.isStatic, isFalse);
-    _assertCodeRange(executable.codeRange, 10, 15);
+    if (includeInformative) {
+      _assertCodeRange(executable.codeRange, 10, 15);
+    }
     expect(findVariable('f', variables: cls.fields), isNull);
     expect(findExecutable('f=', executables: cls.executables), isNull);
     expect(unlinkedUnits[0].publicNamespace.names, hasLength(1));
@@ -5614,7 +5656,9 @@
     expect(executable.isAsynchronous, isFalse);
     expect(executable.isExternal, isFalse);
     expect(executable.isGenerator, isFalse);
-    _assertCodeRange(executable.codeRange, 10, 20);
+    if (includeInformative) {
+      _assertCodeRange(executable.codeRange, 10, 20);
+    }
     expect(findVariable('f', variables: cls.fields), isNull);
     expect(findExecutable('f', executables: cls.executables), isNull);
   }
@@ -5661,8 +5705,8 @@
 
   test_executable_operator() {
     UnlinkedExecutable executable =
-        serializeClassText('class C { C operator+(C c) => null; }').executables[
-            0];
+        serializeClassText('class C { C operator+(C c) => null; }')
+            .executables[0];
     expect(executable.kind, UnlinkedExecutableKind.functionOrMethod);
     expect(executable.name, '+');
     expect(executable.returnType, isNotNull);
@@ -5752,6 +5796,7 @@
   }
 
   test_executable_param_codeRange() {
+    if (!includeInformative) return;
     UnlinkedExecutable executable = serializeExecutableText('f(int x) {}');
     UnlinkedParam parameter = executable.parameters[0];
     _assertCodeRange(parameter.codeRange, 2, 5);
@@ -5812,7 +5857,7 @@
     expect(param.kind, UnlinkedParamKind.positional);
     expect(param.initializer, isNotNull);
     expect(param.defaultValueCode, 'foo');
-    _assertUnlinkedConst(param.initializer.bodyExpr, operators: [
+    assertUnlinkedConst(param.initializer.bodyExpr, operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'foo',
@@ -5834,8 +5879,10 @@
     expect(param.kind, UnlinkedParamKind.named);
     expect(param.initializer, isNotNull);
     expect(param.defaultValueCode, '42');
-    _assertCodeRange(param.codeRange, 3, 5);
-    _assertUnlinkedConst(param.initializer.bodyExpr,
+    if (includeInformative) {
+      _assertCodeRange(param.codeRange, 3, 5);
+    }
+    assertUnlinkedConst(param.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
   }
 
@@ -5853,8 +5900,10 @@
     expect(param.kind, UnlinkedParamKind.positional);
     expect(param.initializer, isNotNull);
     expect(param.defaultValueCode, '42');
-    _assertCodeRange(param.codeRange, 3, 6);
-    _assertUnlinkedConst(param.initializer.bodyExpr,
+    if (includeInformative) {
+      _assertCodeRange(param.codeRange, 3, 6);
+    }
+    assertUnlinkedConst(param.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [42]);
   }
 
@@ -5871,7 +5920,9 @@
     UnlinkedExecutable executable = serializeExecutableText(text);
     expect(executable.parameters, hasLength(1));
     expect(executable.parameters[0].name, 'x');
-    expect(executable.parameters[0].nameOffset, text.indexOf('x'));
+    if (includeInformative) {
+      expect(executable.parameters[0].nameOffset, text.indexOf('x'));
+    }
   }
 
   test_executable_param_no_flags() {
@@ -5976,7 +6027,9 @@
     expect(executable.isAsynchronous, isFalse);
     expect(executable.isExternal, isFalse);
     expect(executable.isGenerator, isFalse);
-    expect(executable.nameOffset, text.indexOf('f'));
+    if (includeInformative) {
+      expect(executable.nameOffset, text.indexOf('f'));
+    }
     expect(findVariable('f'), isNull);
     expect(findExecutable('f'), isNull);
     expect(unlinkedUnits[0].publicNamespace.names, hasLength(1));
@@ -6175,9 +6228,11 @@
         'Future');
     expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].hides[1],
         'Stream');
-    expect(
-        unlinkedUnits[0].publicNamespace.exports[0].combinators[0].offset, 0);
-    expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].end, 0);
+    if (includeInformative) {
+      expect(
+          unlinkedUnits[0].publicNamespace.exports[0].combinators[0].offset, 0);
+      expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].end, 0);
+    }
     expect(linked.exportNames, isNotEmpty);
   }
 
@@ -6293,10 +6348,12 @@
         'Future');
     expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].shows[1],
         'Stream');
-    expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].offset,
-        libraryText.indexOf('show'));
-    expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].end,
-        libraryText.indexOf(';'));
+    if (includeInformative) {
+      expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].offset,
+          libraryText.indexOf('show'));
+      expect(unlinkedUnits[0].publicNamespace.exports[0].combinators[0].end,
+          libraryText.indexOf(';'));
+    }
   }
 
   test_export_typedef() {
@@ -6416,7 +6473,7 @@
 A a = new A();
 final v = (a.b.c.f[1] = 5);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6461,7 +6518,7 @@
 A a = new A();
 final v = (a.b[1].c[2].f[3] = 5);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           // 5
@@ -6510,7 +6567,7 @@
 List<int> a = <int>[0, 1, 2];
 final v = (a[1] = 5);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6542,7 +6599,7 @@
 }
 final v = (new C().f = 5);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6576,7 +6633,7 @@
 }
 final v = (C.f = 1);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6615,7 +6672,7 @@
 A a = new A();
 final v = (a.b.c.f = 1);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6668,7 +6725,7 @@
 int a = 0;
 final v = (a = 1);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6700,7 +6757,7 @@
 import 'a.dart';
 final v = (a = 1);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6732,7 +6789,7 @@
 import 'a.dart' as p;
 final v = (p.a = 1);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -6765,7 +6822,7 @@
 final C c = new C();
 final v = c.items..[1] = 2;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushReference,
@@ -6806,7 +6863,7 @@
 }
 final v = new C()..f1 = 1..f2 += 2;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           // new C()
@@ -6861,7 +6918,7 @@
   ..b = (new B()..fb = 2)
   ..fa2 = 3;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           // new A()
@@ -6929,7 +6986,7 @@
 final A a = new A();
 final v = a..m(5).abs()..m(6);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           // a
@@ -6975,7 +7032,7 @@
 }
 final v = new C().items[5];
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.invokeConstructor,
@@ -7007,7 +7064,7 @@
 }
 final v = new C().f;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.invokeConstructor,
@@ -7034,7 +7091,7 @@
 final v = foo(5, () => 42);
 foo(a, b) {}
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -7063,7 +7120,7 @@
 final v = foo(5, () => 42, () => 43);
 foo(a, b, c) {}
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -7094,7 +7151,7 @@
     UnlinkedVariable variable = serializeVariableText('''
 final v = () { return 42; };
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [UnlinkedExprOperation.pushLocalFunctionReference],
         ints: [0, 0]);
@@ -7107,7 +7164,7 @@
     UnlinkedVariable variable = serializeVariableText('''
 final v = () => 42;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [UnlinkedExprOperation.pushLocalFunctionReference],
         ints: [0, 0]);
@@ -7120,7 +7177,7 @@
     UnlinkedVariable variable = serializeVariableText('''
 final v = ((a, b) {return 42;})(1, 2);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false, operators: [UnlinkedExprOperation.pushNull]);
   }
 
@@ -7131,7 +7188,7 @@
     UnlinkedVariable variable = serializeVariableText('''
 final v = ((a, b) => 42)(1, 2);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false, operators: [UnlinkedExprOperation.pushNull]);
   }
 
@@ -7140,7 +7197,7 @@
       return;
     }
     UnlinkedVariable variable = serializeVariableText('var v = () => 1;');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [1]);
   }
 
@@ -7157,7 +7214,7 @@
     }
     UnlinkedVariable variable =
         serializeVariableText('var v = (x) => (y) => x;');
-    _assertUnlinkedConst(
+    assertUnlinkedConst(
         variable.initializer.localFunctions[0].localFunctions[0].bodyExpr,
         operators: [UnlinkedExprOperation.pushParameter],
         strings: ['x']);
@@ -7168,7 +7225,7 @@
       return;
     }
     UnlinkedVariable variable = serializeVariableText('var v = (x) => x;');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         operators: [UnlinkedExprOperation.pushParameter], strings: ['x']);
   }
 
@@ -7177,7 +7234,7 @@
       return;
     }
     UnlinkedVariable variable = serializeVariableText('var v = (x) => x.f();');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushParameter,
@@ -7200,7 +7257,7 @@
     }
     UnlinkedVariable variable =
         serializeVariableText('var v = (x) => x.y.f();');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushParameter,
@@ -7225,7 +7282,7 @@
     }
     UnlinkedVariable variable =
         serializeVariableText('var x; var v = (b) => (b ? (x) => x : x);');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushParameter,
@@ -7251,7 +7308,7 @@
       return;
     }
     UnlinkedVariable variable = serializeVariableText('var v = (x) => x.y;');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         operators: [
           UnlinkedExprOperation.pushParameter,
           UnlinkedExprOperation.extractProperty
@@ -7268,7 +7325,7 @@
     }
     UnlinkedVariable variable =
         serializeVariableText('var v = (x) => x.y = null;');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushNull,
@@ -7289,7 +7346,7 @@
       return;
     }
     UnlinkedVariable variable = serializeVariableText('var v = (x) => x.y.z;');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         operators: [
           UnlinkedExprOperation.pushParameter,
           UnlinkedExprOperation.extractProperty,
@@ -7308,7 +7365,7 @@
     }
     UnlinkedVariable variable =
         serializeVariableText('var v = (x) => x.y.z = null;');
-    _assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
+    assertUnlinkedConst(variable.initializer.localFunctions[0].bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushNull,
@@ -7336,7 +7393,7 @@
 }
 final v = new C().m(1, b: 2, c: 3);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.invokeConstructor,
@@ -7376,7 +7433,7 @@
 }
 final v = new C().f<int, String>();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.invokeConstructor,
@@ -7416,7 +7473,7 @@
 A a = new A();
 final v = a.b.c.m(10, 20);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -7458,7 +7515,7 @@
 import 'a.dart' as p;
 final v = p.C.m();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.invokeMethodRef,
@@ -7489,7 +7546,7 @@
 final u = null;
 final v = f(u);
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushReference,
@@ -7516,7 +7573,7 @@
 f<T, U>() => null;
 final v = f<int, String>();
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.invokeMethodRef
@@ -7542,7 +7599,7 @@
     UnlinkedVariable variable = serializeVariableText('''
 final v = throw 1 + 2;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -7563,7 +7620,7 @@
     UnlinkedVariable variable = serializeVariableText('''
 final v = 42 as num;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -7585,7 +7642,7 @@
     UnlinkedVariable variable = serializeVariableText('''
 final v = 42 is num;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -7619,11 +7676,12 @@
     UnlinkedVariable variable =
         serializeClassText('class C { static const int i = 0; }').fields[0];
     expect(variable.isConst, isTrue);
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [0]);
   }
 
   test_field_documented() {
+    if (!includeInformative) return;
     String text = '''
 class C {
   /**
@@ -7640,7 +7698,7 @@
     UnlinkedVariable variable =
         serializeClassText('class C { final int i = 0; }').fields[0];
     expect(variable.isFinal, isTrue);
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.pushInt], ints: [0]);
   }
 
@@ -7651,7 +7709,7 @@
   static int m() => 42;
 }''').fields[0];
     expect(variable.isFinal, isTrue);
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -7680,7 +7738,7 @@
   final f = <T>[];
 }''').fields[0];
     expect(variable.isFinal, isTrue);
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         operators: [UnlinkedExprOperation.makeTypedList],
         ints: [0],
         referenceValidators: [(EntityRef r) => checkParamTypeRef(r, 1)]);
@@ -7815,6 +7873,7 @@
   }
 
   test_function_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -7847,6 +7906,7 @@
   }
 
   test_getter_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -7956,8 +8016,10 @@
     expect(unlinkedUnits[0].imports[0].combinators[0].hides, hasLength(2));
     expect(unlinkedUnits[0].imports[0].combinators[0].hides[0], 'Future');
     expect(unlinkedUnits[0].imports[0].combinators[0].hides[1], 'Stream');
-    expect(unlinkedUnits[0].imports[0].combinators[0].offset, 0);
-    expect(unlinkedUnits[0].imports[0].combinators[0].end, 0);
+    if (includeInformative) {
+      expect(unlinkedUnits[0].imports[0].combinators[0].offset, 0);
+      expect(unlinkedUnits[0].imports[0].combinators[0].end, 0);
+    }
   }
 
   test_import_implicit() {
@@ -7966,8 +8028,10 @@
     expect(unlinkedUnits[0].imports, hasLength(1));
     checkDependency(linked.importDependencies[0], 'dart:core', 'dart:core');
     expect(unlinkedUnits[0].imports[0].uri, isEmpty);
-    expect(unlinkedUnits[0].imports[0].uriOffset, 0);
-    expect(unlinkedUnits[0].imports[0].uriEnd, 0);
+    if (includeInformative) {
+      expect(unlinkedUnits[0].imports[0].uriOffset, 0);
+      expect(unlinkedUnits[0].imports[0].uriEnd, 0);
+    }
     expect(unlinkedUnits[0].imports[0].prefixReference, 0);
     expect(unlinkedUnits[0].imports[0].combinators, isEmpty);
     expect(unlinkedUnits[0].imports[0].isImplicit, isTrue);
@@ -8597,6 +8661,7 @@
   }
 
   test_library_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -8714,7 +8779,7 @@
     UnlinkedClass cls = serializeClassText(
         'class A { const A.named(); } @A.named() class C {}');
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8733,7 +8798,7 @@
     UnlinkedClass cls = serializeClassText(
         'import "foo.dart" as foo; @foo.A.named() class C {}');
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8755,7 +8820,7 @@
         'import "foo.dart" as foo; @foo.A.named() class C {}',
         allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8776,7 +8841,7 @@
         'import "foo.dart" as foo; @foo.A.named() class C {}',
         allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8796,7 +8861,7 @@
     UnlinkedClass cls =
         serializeClassText('@A.named() class C {}', allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8814,7 +8879,7 @@
     UnlinkedClass cls = serializeClassText('class A {} @A.named() class C {}',
         allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8832,7 +8897,7 @@
     UnlinkedClass cls =
         serializeClassText('class A { const A(); } @A() class C {}');
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8848,7 +8913,7 @@
     UnlinkedClass cls =
         serializeClassText('import "foo.dart" as foo; @foo.A() class C {}');
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8865,7 +8930,7 @@
         'import "foo.dart" as foo; @foo.A() class C {}',
         allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8880,7 +8945,7 @@
     UnlinkedClass cls =
         serializeClassText('@A() class C {}', allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
       0,
@@ -8895,7 +8960,7 @@
     UnlinkedClass cls =
         serializeClassText('class A { const A(x); } @A(null) class C {}');
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.pushNull,
       UnlinkedExprOperation.invokeConstructor,
     ], ints: [
@@ -9025,13 +9090,13 @@
         serializeClassText('const a = null, b = null; @a @b class C {}');
     List<UnlinkedExpr> annotations = cls.annotations;
     expect(annotations, hasLength(2));
-    _assertUnlinkedConst(annotations[0], operators: [
+    assertUnlinkedConst(annotations[0], operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'a',
           expectedKind: ReferenceKind.topLevelPropertyAccessor)
     ]);
-    _assertUnlinkedConst(annotations[1], operators: [
+    assertUnlinkedConst(annotations[1], operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'b',
@@ -9050,7 +9115,7 @@
     UnlinkedClass cls =
         serializeClassText('import "a.dart" as a; @a.b class C {}');
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, absUri('/a.dart'), 'a.dart', 'b',
@@ -9065,7 +9130,7 @@
         'import "a.dart" as a; @a.b class C {}',
         allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'b',
@@ -9120,7 +9185,7 @@
   test_metadata_variable_unresolved() {
     UnlinkedClass cls = serializeClassText('@a class C {}', allowErrors: true);
     expect(cls.annotations, hasLength(1));
-    _assertUnlinkedConst(cls.annotations[0], operators: [
+    assertUnlinkedConst(cls.annotations[0], operators: [
       UnlinkedExprOperation.pushReference
     ], referenceValidators: [
       (EntityRef r) => checkTypeRef(r, null, null, 'a',
@@ -9129,6 +9194,7 @@
   }
 
   test_method_documented() {
+    if (!includeInformative) return;
     String text = '''
 class C {
   /**
@@ -9340,6 +9406,7 @@
   }
 
   test_setter_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -9363,8 +9430,8 @@
 
   test_setter_inferred_type_nonstatic_explicit_return() {
     UnlinkedExecutable f =
-        serializeClassText('class C { void set f(int value) {} }').executables[
-            0];
+        serializeClassText('class C { void set f(int value) {} }')
+            .executables[0];
     expect(f.inferredReturnTypeSlot, 0);
   }
 
@@ -9608,6 +9675,7 @@
   }
 
   test_type_param_codeRange() {
+    if (!includeInformative) return;
     UnlinkedClass cls =
         serializeClassText('class A {} class C<T extends A> {}');
     UnlinkedTypeParam typeParameter = cls.typeParameters[0];
@@ -9861,11 +9929,13 @@
   }
 
   test_typedef_codeRange() {
+    if (!includeInformative) return;
     UnlinkedTypedef type = serializeTypedefText('typedef F();');
     _assertCodeRange(type.codeRange, 0, 12);
   }
 
   test_typedef_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -9881,7 +9951,9 @@
     String text = 'typedef F();';
     UnlinkedTypedef type = serializeTypedefText(text);
     expect(type.name, 'F');
-    expect(type.nameOffset, text.indexOf('F'));
+    if (includeInformative) {
+      expect(type.nameOffset, text.indexOf('F'));
+    }
     expect(unlinkedUnits[0].publicNamespace.names, hasLength(1));
     expect(
         unlinkedUnits[0].publicNamespace.names[0].kind, ReferenceKind.typedef);
@@ -9950,6 +10022,7 @@
   }
 
   test_unit_codeRange() {
+    if (!includeInformative) return;
     serializeLibraryText('  int a = 1;  ');
     UnlinkedUnit unit = unlinkedUnits[0];
     _assertCodeRange(unit.codeRange, 0, 14);
@@ -10028,7 +10101,9 @@
   test_variable() {
     String text = 'int i;';
     UnlinkedVariable v = serializeVariableText(text, variableName: 'i');
-    expect(v.nameOffset, text.indexOf('i;'));
+    if (includeInformative) {
+      expect(v.nameOffset, text.indexOf('i;'));
+    }
     expect(findExecutable('i'), isNull);
     expect(findExecutable('i='), isNull);
     expect(unlinkedUnits[0].publicNamespace.names, hasLength(2));
@@ -10043,6 +10118,7 @@
   }
 
   test_variable_codeRange() {
+    if (!includeInformative) return;
     serializeLibraryText(' int a = 1, b = 22;');
     List<UnlinkedVariable> variables = unlinkedUnits[0].variables;
     _assertCodeRange(variables[0].codeRange, 1, 18);
@@ -10056,6 +10132,7 @@
   }
 
   test_variable_documented() {
+    if (!includeInformative) return;
     String text = '''
 // Extra comment so doc comment offset != 0
 /**
@@ -10108,7 +10185,9 @@
     UnlinkedVariable variable = serializeVariableText('var v = 42;');
     UnlinkedExecutable initializer = variable.initializer;
     expect(initializer, isNotNull);
-    expect(initializer.nameOffset, 8);
+    if (includeInformative) {
+      expect(initializer.nameOffset, 8);
+    }
     expect(initializer.name, isEmpty);
     expect(initializer.localFunctions, isEmpty);
     expect(initializer.localVariables, isEmpty);
@@ -10125,36 +10204,50 @@
     UnlinkedVariable variable = serializeVariableText(text);
     UnlinkedExecutable initializer = variable.initializer;
     expect(initializer, isNotNull);
-    expect(initializer.nameOffset, text.indexOf('<dynamic, dynamic>{"1'));
+    if (includeInformative) {
+      expect(initializer.nameOffset, text.indexOf('<dynamic, dynamic>{"1'));
+    }
     expect(initializer.name, isEmpty);
     expect(initializer.localFunctions, hasLength(2));
     // closure: () { f1() {} var v1; }
     {
       UnlinkedExecutable closure = initializer.localFunctions[0];
-      expect(closure.nameOffset, text.indexOf('() { f1()'));
+      if (includeInformative) {
+        expect(closure.nameOffset, text.indexOf('() { f1()'));
+      }
       expect(closure.name, isEmpty);
       // closure - f1
       expect(closure.localFunctions, hasLength(1));
       expect(closure.localFunctions[0].name, 'f1');
-      expect(closure.localFunctions[0].nameOffset, text.indexOf('f1()'));
+      if (includeInformative) {
+        expect(closure.localFunctions[0].nameOffset, text.indexOf('f1()'));
+      }
       // closure - v1
       expect(closure.localVariables, hasLength(1));
       expect(closure.localVariables[0].name, 'v1');
-      expect(closure.localVariables[0].nameOffset, text.indexOf('v1;'));
+      if (includeInformative) {
+        expect(closure.localVariables[0].nameOffset, text.indexOf('v1;'));
+      }
     }
     // closure: () { f2() {} var v2; }
     {
       UnlinkedExecutable closure = initializer.localFunctions[1];
-      expect(closure.nameOffset, text.indexOf('() { f2()'));
+      if (includeInformative) {
+        expect(closure.nameOffset, text.indexOf('() { f2()'));
+      }
       expect(closure.name, isEmpty);
       // closure - f1
       expect(closure.localFunctions, hasLength(1));
       expect(closure.localFunctions[0].name, 'f2');
-      expect(closure.localFunctions[0].nameOffset, text.indexOf('f2()'));
+      if (includeInformative) {
+        expect(closure.localFunctions[0].nameOffset, text.indexOf('f2()'));
+      }
       // closure - v1
       expect(closure.localVariables, hasLength(1));
       expect(closure.localVariables[0].name, 'v2');
-      expect(closure.localVariables[0].nameOffset, text.indexOf('v2;'));
+      if (includeInformative) {
+        expect(closure.localVariables[0].nameOffset, text.indexOf('v2;'));
+      }
     }
   }
 
@@ -10263,7 +10356,7 @@
 int a = 0;
 final v = $expr;
     ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.pushInt,
@@ -10330,7 +10423,7 @@
 int a = 0;
 final v = $expr;
 ''');
-    _assertUnlinkedConst(variable.initializer.bodyExpr,
+    assertUnlinkedConst(variable.initializer.bodyExpr,
         isValidConst: false,
         operators: [
           UnlinkedExprOperation.assignToRef,
@@ -10353,7 +10446,7 @@
   /**
    * TODO(scheglov) rename "Const" to "Expr" everywhere
    */
-  void _assertUnlinkedConst(UnlinkedExpr constExpr,
+  void assertUnlinkedConst(UnlinkedExpr constExpr,
       {bool isValidConst: true,
       List<UnlinkedExprOperation> operators: const <UnlinkedExprOperation>[],
       List<UnlinkedExprAssignOperator> assignmentOperators:
diff --git a/pkg/analyzer/test/src/task/strong/checker_test.dart b/pkg/analyzer/test/src/task/strong/checker_test.dart
index 6c22865..6ad54c7 100644
--- a/pkg/analyzer/test/src/task/strong/checker_test.dart
+++ b/pkg/analyzer/test/src/task/strong/checker_test.dart
@@ -3991,6 +3991,27 @@
 ''');
   }
 
+  void test_universalFunctionSubtyping() {
+    checkFile(r'''
+dynamic foo<T>(dynamic x) => x;
+
+void takesDtoD(dynamic f(dynamic x)) {}
+
+void test() {
+  // here we currently infer an instantiation.
+  takesDtoD(/*pass should be error:INVALID_ASSIGNMENT*/foo);
+}
+
+class A {
+  dynamic method(dynamic x) => x;
+}
+
+class B extends A {
+  /*error:INVALID_METHOD_OVERRIDE*/T method<T>(T x) => x;
+}
+    ''');
+  }
+
   void test_voidSubtyping() {
     // Regression test for https://github.com/dart-lang/sdk/issues/25069
     checkFile('''
diff --git a/pkg/analyzer/test/src/task/strong/inferred_type_test.dart b/pkg/analyzer/test/src/task/strong/inferred_type_test.dart
index 7979880..db39828 100644
--- a/pkg/analyzer/test/src/task/strong/inferred_type_test.dart
+++ b/pkg/analyzer/test/src/task/strong/inferred_type_test.dart
@@ -2263,26 +2263,8 @@
   dynamic g(int x) => x;
 }
 class D extends C {
-  T m<T>(T x) => x;
-  T g<T>(T x) => x;
-}
-main() {
-  int y = /*info:DYNAMIC_CAST*/(/*info:UNNECESSARY_CAST*/new D() as C).m(42);
-  print(y);
-}
-  ''');
-  }
-
-  void test_genericMethods_handleOverrideOfNonGenericWithGeneric_comment() {
-    // Regression test for crash when adding genericity
-    checkFile('''
-class C {
-  m(x) => x;
-  dynamic g(int x) => x;
-}
-class D extends C {
-  /*=T*/ m/*<T>*/(/*=T*/ x) => x;
-  /*=T*/ g/*<T>*/(/*=T*/ x) => x;
+  /*error:INVALID_METHOD_OVERRIDE*/T m<T>(T x) => x;
+  /*error:INVALID_METHOD_OVERRIDE*/T g<T>(T x) => x;
 }
 main() {
   int y = /*info:DYNAMIC_CAST*/(/*info:UNNECESSARY_CAST*/new D() as C).m(42);
diff --git a/pkg/analyzer_cli/lib/src/build_mode.dart b/pkg/analyzer_cli/lib/src/build_mode.dart
index a8e9757..5beef11 100644
--- a/pkg/analyzer_cli/lib/src/build_mode.dart
+++ b/pkg/analyzer_cli/lib/src/build_mode.dart
@@ -270,7 +270,8 @@
     ]);
 
     // Set context options.
-    Driver.setAnalysisContextOptions(resourceProvider, context, options,
+    Driver.setAnalysisContextOptions(
+        resourceProvider, context.sourceFactory, context, options,
         (AnalysisOptionsImpl contextOptions) {
       if (options.buildSummaryOnlyDiet) {
         contextOptions.analyzeFunctionBodies = false;
diff --git a/pkg/analyzer_cli/lib/src/driver.dart b/pkg/analyzer_cli/lib/src/driver.dart
index 16ec22d..35caf04 100644
--- a/pkg/analyzer_cli/lib/src/driver.dart
+++ b/pkg/analyzer_cli/lib/src/driver.dart
@@ -491,13 +491,6 @@
     // Create a context.
     _context = AnalysisEngine.instance.createAnalysisContext();
 
-    AnalyzeFunctionBodiesPredicate dietParsingPolicy =
-        _chooseDietParsingPolicy(options);
-    setAnalysisContextOptions(resourceProvider, _context, options,
-        (AnalysisOptionsImpl contextOptions) {
-      contextOptions.analyzeFunctionBodiesPredicate = dietParsingPolicy;
-    });
-
     // Find package info.
     _PackageInfo packageInfo = _findPackages(options);
 
@@ -528,6 +521,14 @@
     SourceFactory sourceFactory = _chooseUriResolutionPolicy(
         options, embedderMap, packageInfo, summaryDataStore);
 
+    AnalyzeFunctionBodiesPredicate dietParsingPolicy =
+        _chooseDietParsingPolicy(options);
+    setAnalysisContextOptions(
+        resourceProvider, sourceFactory, _context, options,
+        (AnalysisOptionsImpl contextOptions) {
+      contextOptions.analyzeFunctionBodiesPredicate = dietParsingPolicy;
+    });
+
     _context.sourceFactory = sourceFactory;
     _context.resultProvider =
         new InputPackagesResultProvider(_context, summaryDataStore);
@@ -680,6 +681,7 @@
 
   static void setAnalysisContextOptions(
       file_system.ResourceProvider resourceProvider,
+      SourceFactory sourceFactory,
       AnalysisContext context,
       CommandLineOptions options,
       void configureContextOptions(AnalysisOptionsImpl contextOptions)) {
@@ -704,7 +706,7 @@
     context.analysisOptions = contextOptions;
 
     // Process analysis options file (and notify all interested parties).
-    _processAnalysisOptions(resourceProvider, context, options);
+    _processAnalysisOptions(resourceProvider, sourceFactory, context, options);
   }
 
   /// Perform a deep comparison of two string lists.
@@ -761,14 +763,16 @@
 
   static void _processAnalysisOptions(
       file_system.ResourceProvider resourceProvider,
+      SourceFactory sourceFactory,
       AnalysisContext context,
       CommandLineOptions options) {
     file_system.File file = _getOptionsFile(resourceProvider, options);
     List<OptionsProcessor> optionsProcessors =
         AnalysisEngine.instance.optionsPlugin.optionsProcessors;
+
     try {
       AnalysisOptionsProvider analysisOptionsProvider =
-          new AnalysisOptionsProvider();
+          new AnalysisOptionsProvider(sourceFactory);
       Map<String, YamlNode> optionMap =
           analysisOptionsProvider.getOptionsFromFile(file);
       optionsProcessors.forEach(
diff --git a/pkg/analyzer_cli/test/data/options_include_directive_tests_project/.analysis_options b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/.analysis_options
new file mode 100644
index 0000000..7d95424
--- /dev/null
+++ b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/.analysis_options
@@ -0,0 +1 @@
+include: other_options.yaml
diff --git a/pkg/analyzer_cli/test/data/options_include_directive_tests_project/_packages b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/_packages
new file mode 100644
index 0000000..574bcbd
--- /dev/null
+++ b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/_packages
@@ -0,0 +1,3 @@
+# Generated by pub on 2016-11-30 13:02:00.280796.
+foo:pkg/foo/lib/
+options_include_directive_tests_project:lib/
diff --git a/pkg/analyzer_cli/test/data/options_include_directive_tests_project/lib/test_file.dart b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/lib/test_file.dart
new file mode 100644
index 0000000..c53a7e0
--- /dev/null
+++ b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/lib/test_file.dart
@@ -0,0 +1,16 @@
+// 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.
+
+library analyzer_cli.test.data.options_include_directive_test_project.test_file;
+
+
+int foo() {
+
+  int x = baz(); // Undefined function.
+  if (x == 0) {
+    print('x is zero');
+  } else ; // Empty else statement
+
+  // Missing return
+}
diff --git a/pkg/analyzer_cli/test/data/options_include_directive_tests_project/other_options.yaml b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/other_options.yaml
new file mode 100644
index 0000000..c27dd4a
--- /dev/null
+++ b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/other_options.yaml
@@ -0,0 +1 @@
+include: package:foo/foo_package_options.yaml
diff --git a/pkg/analyzer_cli/test/data/options_include_directive_tests_project/pkg/foo/lib/foo_package_options.yaml b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/pkg/foo/lib/foo_package_options.yaml
new file mode 100644
index 0000000..89c0bf6a
--- /dev/null
+++ b/pkg/analyzer_cli/test/data/options_include_directive_tests_project/pkg/foo/lib/foo_package_options.yaml
@@ -0,0 +1,13 @@
+analyzer:
+  strong-mode: true
+  errors:
+    unused_local_variable: ignore
+    missing_return: error
+    undefined_function: warning
+  language:
+    enableSuperMixins: true
+
+linter:
+ rules:
+   # see catalog here: http://dart-lang.github.io/linter/lints/
+   - avoid_empty_else
diff --git a/pkg/analyzer_cli/test/driver_test.dart b/pkg/analyzer_cli/test/driver_test.dart
index 222d96d..f582e59 100644
--- a/pkg/analyzer_cli/test/driver_test.dart
+++ b/pkg/analyzer_cli/test/driver_test.dart
@@ -306,6 +306,25 @@
 
       createTests('old', AnalysisEngine.ANALYSIS_OPTIONS_FILE);
       createTests('new', AnalysisEngine.ANALYSIS_OPTIONS_YAML_FILE);
+
+      test('include directive', () {
+        String testDir = path.join(
+            testDirectory, 'data', 'options_include_directive_tests_project');
+        drive(
+          path.join(testDir, 'lib', 'test_file.dart'),
+          args: [
+            '--fatal-warnings',
+            '--packages',
+            path.join(testDir, '_packages'),
+          ],
+          options: path.join(testDir, '.analysis_options'),
+        );
+        expect(exitCode, 3);
+        expect(outSink.toString(),
+            contains('but doesn\'t end with a return statement.'));
+        expect(outSink.toString(), contains('isn\'t defined'));
+        expect(outSink.toString(), contains('Avoid empty else statements.'));
+      });
     });
 
     void createTests(String designator, String optionsFileName) {
diff --git a/pkg/compiler/lib/src/apiimpl.dart b/pkg/compiler/lib/src/apiimpl.dart
index dbff8df..fc92457 100644
--- a/pkg/compiler/lib/src/apiimpl.dart
+++ b/pkg/compiler/lib/src/apiimpl.dart
@@ -381,8 +381,7 @@
     // Private libraries are not exposed to the users.
     if (libraryName.startsWith("_")) return null;
 
-    Uri libraryUri =
-        compiler.resolvedUriTranslator.sdkLibraries[libraryName];
+    Uri libraryUri = compiler.resolvedUriTranslator.sdkLibraries[libraryName];
     if (libraryUri != null && libraryUri.scheme != "unsupported") {
       // Dart2js always "supports" importing 'dart:mirrors' but will abort
       // the compilation at a later point if the backend doesn't support
diff --git a/pkg/compiler/lib/src/compiler.dart b/pkg/compiler/lib/src/compiler.dart
index db282a3..16ef47d 100644
--- a/pkg/compiler/lib/src/compiler.dart
+++ b/pkg/compiler/lib/src/compiler.dart
@@ -1792,8 +1792,6 @@
   }
 
   SourceSpan spanFromSpannable(Spannable node) {
-    // TODO(johnniwinther): Disallow `node == null` ?
-    if (node == null) return null;
     if (node == CURRENT_ELEMENT_SPANNABLE) {
       node = currentElement;
     } else if (node == NO_LOCATION_SPANNABLE) {
diff --git a/pkg/compiler/lib/src/diagnostics/messages.dart b/pkg/compiler/lib/src/diagnostics/messages.dart
index a65c6ef..4b6e33ad 100644
--- a/pkg/compiler/lib/src/diagnostics/messages.dart
+++ b/pkg/compiler/lib/src/diagnostics/messages.dart
@@ -385,6 +385,7 @@
   PATCH_POINT_TO_SETTER,
   PATCH_REQUIRED_PARAMETER_COUNT_MISMATCH,
   PATCH_RETURN_TYPE_MISMATCH,
+  PATCH_TYPE_VARIABLES_MISMATCH,
   PLEASE_REPORT_THE_CRASH,
   POSITIONAL_PARAMETER_WITH_EQUALS,
   POTENTIAL_MUTATION,
@@ -1239,12 +1240,14 @@
           ]),
 
       MessageKind.TYPE_VARIABLE_FROM_METHOD_CONSIDERED_DYNAMIC:
-      const MessageTemplate(
-          MessageKind.TYPE_VARIABLE_FROM_METHOD_CONSIDERED_DYNAMIC,
-          "Method type variables are treated as `dynamic` in `as` expressions.",
-          howToFix: "Try using the upper bound of the type variable, or check "
-              "that the blind success of the test does not introduce bugs.",
-          examples: const [
+          const MessageTemplate(
+              MessageKind.TYPE_VARIABLE_FROM_METHOD_CONSIDERED_DYNAMIC,
+              "Method type variables are treated as `dynamic` in `as` "
+              "expressions.",
+              howToFix:
+                  "Try using the upper bound of the type variable, or check "
+                  "that the blind success of the test does not introduce bugs.",
+              examples: const [
             """
 // Method type variables are not reified, so they cannot be tested dynamically.
 bool f<T>(Object o) => o as T;
@@ -3530,6 +3533,11 @@
       // Patch errors start.
       //////////////////////////////////////////////////////////////////////////////
 
+      MessageKind.PATCH_TYPE_VARIABLES_MISMATCH: const MessageTemplate(
+          MessageKind.PATCH_TYPE_VARIABLES_MISMATCH,
+          "Patch type variables do not match "
+          "type variables on origin method '#{methodName}'."),
+
       MessageKind.PATCH_RETURN_TYPE_MISMATCH: const MessageTemplate(
           MessageKind.PATCH_RETURN_TYPE_MISMATCH,
           "Patch return type '#{patchReturnType}' does not match "
diff --git a/pkg/compiler/lib/src/elements/elements.dart b/pkg/compiler/lib/src/elements/elements.dart
index 178ba03..66eec37 100644
--- a/pkg/compiler/lib/src/elements/elements.dart
+++ b/pkg/compiler/lib/src/elements/elements.dart
@@ -1417,6 +1417,14 @@
 /// [GenericElement] defines the common interface for generic functions and
 /// [TypeDeclarationElement].
 abstract class GenericElement extends Element implements AstElement {
+  /// Do not use [computeType] outside of the resolver.
+  ///
+  /// Trying to access a type that has not been computed in resolution is an
+  /// error and calling [computeType] covers that error.
+  /// This method will go away!
+  @deprecated
+  DartType computeType(Resolution resolution);
+
   /**
    * The type variables declared on this declaration. The type variables are not
    * available until the type of the element has been computed through
diff --git a/pkg/compiler/lib/src/elements/entities.dart b/pkg/compiler/lib/src/elements/entities.dart
index 7c03e03..ce1fc56 100644
--- a/pkg/compiler/lib/src/elements/entities.dart
+++ b/pkg/compiler/lib/src/elements/entities.dart
@@ -25,6 +25,7 @@
   bool get isField;
   bool get isFunction;
   bool get isGetter;
+  bool get isSetter;
   bool get isAssignable;
   ClassEntity get enclosingClass;
 }
diff --git a/pkg/compiler/lib/src/enqueue.dart b/pkg/compiler/lib/src/enqueue.dart
index cdd46e9..eb88a0b 100644
--- a/pkg/compiler/lib/src/enqueue.dart
+++ b/pkg/compiler/lib/src/enqueue.dart
@@ -25,18 +25,18 @@
         ConstructorElement,
         Element,
         Entity,
-        FunctionElement,
         LibraryElement,
         LocalFunctionElement,
-        TypedElement;
+        MemberElement;
+import 'elements/entities.dart';
 import 'native/native.dart' as native;
 import 'types/types.dart' show TypeMaskStrategy;
-import 'universe/selector.dart' show Selector;
 import 'universe/world_builder.dart';
 import 'universe/use.dart'
     show DynamicUse, StaticUse, StaticUseKind, TypeUse, TypeUseKind;
 import 'universe/world_impact.dart'
     show ImpactStrategy, ImpactUseCase, WorldImpact, WorldImpactVisitor;
+import 'util/enumset.dart';
 import 'util/util.dart' show Setlet;
 import 'world.dart' show OpenWorld;
 
@@ -121,91 +121,76 @@
 
 abstract class EnqueuerImpl extends Enqueuer {
   CompilerTask get task;
-  void processInstantiatedClassMembers(ClassElement cls);
-  void processInstantiatedClassMember(ClassElement cls, Element member);
-  void registerStaticUse(StaticUse staticUse);
-  void registerStaticUseInternal(StaticUse staticUse);
-  void registerTypeUse(TypeUse typeUse);
-  void registerTypeUseInternal(TypeUse typeUse);
-  void registerDynamicUse(DynamicUse dynamicUse);
-  void handleUnseenSelectorInternal(DynamicUse dynamicUse);
+  EnqueuerStrategy get strategy;
+  void checkClass(ClassElement cls);
+  void processStaticUse(StaticUse staticUse);
+  void processTypeUse(TypeUse typeUse);
+  void processDynamicUse(DynamicUse dynamicUse);
 }
 
 /// [Enqueuer] which is specific to resolution.
 class ResolutionEnqueuer extends EnqueuerImpl {
+  static const ImpactUseCase IMPACT_USE =
+      const ImpactUseCase('ResolutionEnqueuer');
+
   final CompilerTask task;
   final String name;
-  final Resolution resolution;
-  final CompilerOptions options;
+  final Resolution _resolution;
+  final CompilerOptions _options;
   final Backend backend;
-  final GlobalDependencyRegistry globalDependencies;
-  final CommonElements commonElements;
+  final GlobalDependencyRegistry _globalDependencies;
+  final CommonElements _commonElements;
   final native.NativeEnqueuer nativeEnqueuer;
 
   final EnqueuerStrategy strategy;
-  final Map<String, Set<Element>> instanceMembersByName =
-      new Map<String, Set<Element>>();
-  final Map<String, Set<Element>> instanceFunctionsByName =
-      new Map<String, Set<Element>>();
-  final Set<ClassElement> _processedClasses = new Set<ClassElement>();
-  Set<ClassElement> recentClasses = new Setlet<ClassElement>();
+  Set<ClassElement> _recentClasses = new Setlet<ClassElement>();
   final ResolutionWorldBuilderImpl _universe;
 
   bool queueIsClosed = false;
 
-  WorldImpactVisitor impactVisitor;
+  WorldImpactVisitor _impactVisitor;
+
+  /// All declaration elements that have been processed by the resolver.
+  final Set<AstElement> processedElements = new Set<AstElement>();
+
+  final Queue<WorkItem> _queue = new Queue<WorkItem>();
+
+  /// Queue of deferred resolution actions to execute when the resolution queue
+  /// has been emptied.
+  final Queue<_DeferredAction> _deferredQueue = new Queue<_DeferredAction>();
 
   ResolutionEnqueuer(
       this.task,
-      this.options,
-      this.resolution,
+      this._options,
+      Resolution resolution,
       this.strategy,
-      this.globalDependencies,
+      this._globalDependencies,
       Backend backend,
-      CommonElements commonElements,
+      this._commonElements,
       CacheStrategy cacheStrategy,
       [this.name = 'resolution enqueuer'])
       : this.backend = backend,
-        this.commonElements = commonElements,
+        this._resolution = resolution,
         this.nativeEnqueuer = backend.nativeResolutionEnqueuer(),
-        processedElements = new Set<AstElement>(),
-        queue = new Queue<ResolutionWorkItem>(),
-        deferredQueue = new Queue<_DeferredAction>(),
         _universe = new ResolutionWorldBuilderImpl(
-            backend, commonElements, cacheStrategy, const TypeMaskStrategy()) {
-    impactVisitor = new EnqueuerImplImpactVisitor(this);
+            backend, resolution, cacheStrategy, const TypeMaskStrategy()) {
+    _impactVisitor = new EnqueuerImplImpactVisitor(this);
   }
 
   ResolutionWorldBuilder get universe => _universe;
 
-  OpenWorld get openWorld => universe.openWorld;
+  OpenWorld get _openWorld => universe.openWorld;
 
-  bool get queueIsEmpty => queue.isEmpty;
+  bool get queueIsEmpty => _queue.isEmpty;
 
-  DiagnosticReporter get reporter => resolution.reporter;
+  DiagnosticReporter get _reporter => _resolution.reporter;
 
-  bool isClassProcessed(ClassElement cls) => _processedClasses.contains(cls);
-
-  Iterable<ClassElement> get processedClasses => _processedClasses;
-
-  /**
-   * Documentation wanted -- johnniwinther
-   *
-   * Invariant: [element] must be a declaration element.
-   */
-  void addToWorkList(Element element) {
-    assert(invariant(element, element.isDeclaration));
-    internalAddToWorkList(element);
-  }
+  Iterable<ClassElement> get processedClasses => _universe.processedClasses;
 
   void applyImpact(WorldImpact worldImpact, {Element impactSource}) {
     if (worldImpact.isEmpty) return;
     impactStrategy.visitImpact(
-        impactSource, worldImpact, impactVisitor, impactUse);
-  }
-
-  void registerInstantiatedType(InterfaceType type) {
-    _registerInstantiatedType(type, globalDependency: true);
+        impactSource, worldImpact, _impactVisitor, impactUse);
   }
 
   void _registerInstantiatedType(InterfaceType type,
@@ -215,27 +200,17 @@
       bool globalDependency: false,
       bool isRedirection: false}) {
     task.measure(() {
-      ClassElement cls = type.element;
-      cls.ensureResolved(resolution);
-      bool isNative = backend.isNative(cls);
-      _universe.registerTypeInstantiation(type,
+      _universe.registerTypeInstantiation(type, _applyClassUse,
           constructor: constructor,
-          isNative: isNative,
           byMirrors: mirrorUsage,
-          isRedirection: isRedirection, onImplemented: (ClassElement cls) {
-        applyImpact(backend.registerImplementedClass(cls, forResolution: true));
-      });
+          isRedirection: isRedirection);
       if (globalDependency && !mirrorUsage) {
-        globalDependencies.registerDependency(type.element);
+        _globalDependencies.registerDependency(type.element);
       }
       if (nativeUsage) {
         nativeEnqueuer.onInstantiatedType(type);
       }
       backend.registerInstantiatedType(type);
-      // TODO(johnniwinther): Share this reasoning with [Universe].
-      if (!cls.isAbstract || isNative || mirrorUsage) {
-        processInstantiatedClass(cls);
-      }
     });
   }
 
@@ -243,197 +218,63 @@
     return strategy.checkEnqueuerConsistency(this);
   }
 
-  void processInstantiatedClassMembers(ClassElement cls) {
-    strategy.processInstantiatedClass(this, cls);
+  void checkClass(ClassElement cls) {
+    _universe.processClassMembers(cls,
+        (MemberElement member, EnumSet<MemberUse> useSet) {
+      if (useSet.isNotEmpty) {
+        _reporter.internalError(member,
+            'Unenqueued use of $member: ${useSet.iterable(MemberUse.values)}');
+      }
+    });
   }
 
-  void processInstantiatedClassMember(ClassElement cls, Element member) {
-    assert(invariant(member, member.isDeclaration));
-    if (isProcessed(member)) return;
-    if (!member.isInstanceMember) return;
-    String memberName = member.name;
-
-    if (member.isField) {
-      // The obvious thing to test here would be "member.isNative",
-      // however, that only works after metadata has been parsed/analyzed,
-      // and that may not have happened yet.
-      // So instead we use the enclosing class, which we know have had
-      // its metadata parsed and analyzed.
-      // Note: this assumes that there are no non-native fields on native
-      // classes, which may not be the case when a native class is subclassed.
-      if (backend.isNative(cls)) {
-        openWorld.registerUsedElement(member);
-        if (_universe.hasInvokedGetter(member, openWorld) ||
-            _universe.hasInvocation(member, openWorld)) {
-          addToWorkList(member);
-          return;
-        }
-        if (_universe.hasInvokedSetter(member, openWorld)) {
-          addToWorkList(member);
-          return;
-        }
-        // Native fields need to go into instanceMembersByName as they
-        // are virtual instantiation points and escape points.
-      } else {
-        // All field initializers must be resolved as they could
-        // have an observable side-effect (and cannot be tree-shaken
-        // away).
-        addToWorkList(member);
-        return;
-      }
-    } else if (member.isFunction) {
-      FunctionElement function = member;
-      function.computeType(resolution);
+  /// Callback for applying the first seen use of a [member].
+  void _applyFirstMemberUse(MemberElement member, EnumSet<MemberUse> useSet) {
+    ClassElement cls = member.enclosingClass;
+    if (member.isFunction) {
+      MemberElement function = member;
       if (function.name == Identifiers.noSuchMethod_) {
-        registerNoSuchMethod(function);
+        _registerNoSuchMethod(function);
       }
       if (function.name == Identifiers.call && !cls.typeVariables.isEmpty) {
         _registerCallMethodWithFreeTypeVariables(function);
       }
-      // If there is a property access with the same name as a method we
-      // need to emit the method.
-      if (_universe.hasInvokedGetter(function, openWorld)) {
-        registerClosurizedMember(function);
-        addToWorkList(function);
-        return;
-      }
-      // Store the member in [instanceFunctionsByName] to catch
-      // getters on the function.
-      instanceFunctionsByName
-          .putIfAbsent(memberName, () => new Set<Element>())
-          .add(member);
-      if (_universe.hasInvocation(function, openWorld)) {
-        addToWorkList(function);
-        return;
-      }
-    } else if (member.isGetter) {
-      FunctionElement getter = member;
-      getter.computeType(resolution);
-      if (_universe.hasInvokedGetter(getter, openWorld)) {
-        addToWorkList(getter);
-        return;
-      }
-      // We don't know what selectors the returned closure accepts. If
-      // the set contains any selector we have to assume that it matches.
-      if (_universe.hasInvocation(getter, openWorld)) {
-        addToWorkList(getter);
-        return;
-      }
-    } else if (member.isSetter) {
-      FunctionElement setter = member;
-      setter.computeType(resolution);
-      if (_universe.hasInvokedSetter(setter, openWorld)) {
-        addToWorkList(setter);
-        return;
-      }
     }
-
-    // The element is not yet used. Add it to the list of instance
-    // members to still be processed.
-    instanceMembersByName
-        .putIfAbsent(memberName, () => new Set<Element>())
-        .add(member);
+    _applyMemberUse(member, useSet);
   }
 
-  void processInstantiatedClass(ClassElement cls) {
+  /// Callback for applying the use of a [member].
+  void _applyMemberUse(Entity member, EnumSet<MemberUse> useSet) {
+    if (useSet.contains(MemberUse.NORMAL)) {
+      _addToWorkList(member);
+    }
+    if (useSet.contains(MemberUse.CLOSURIZE)) {
+      _registerClosurizedMember(member);
+    }
+  }
+
+  /// Callback for applying the use of a [cls].
+  void _applyClassUse(ClassEntity cls, EnumSet<ClassUse> useSet) {
+    if (useSet.contains(ClassUse.INSTANTIATED)) {
+      _recentClasses.add(cls);
+      _universe.processClassMembers(cls, _applyFirstMemberUse);
+      // We only tell the backend once that [cls] was instantiated, so
+      // any additional dependencies must be treated as global
+      // dependencies.
+      applyImpact(backend.registerInstantiatedClass(cls, forResolution: true));
+    }
+    if (useSet.contains(ClassUse.IMPLEMENTED)) {
+      applyImpact(backend.registerImplementedClass(cls, forResolution: true));
+    }
+  }
+
+  void processDynamicUse(DynamicUse dynamicUse) {
     task.measure(() {
-      if (_processedClasses.contains(cls)) return;
-      // The class must be resolved to compute the set of all
-      // supertypes.
-      cls.ensureResolved(resolution);
-
-      void processClass(ClassElement superclass) {
-        if (_processedClasses.contains(superclass)) return;
-
-        _processedClasses.add(superclass);
-        recentClasses.add(superclass);
-        superclass.ensureResolved(resolution);
-        superclass.implementation.forEachMember(processInstantiatedClassMember);
-        resolution.ensureClassMembers(superclass);
-        // We only tell the backend once that [superclass] was instantiated, so
-        // any additional dependencies must be treated as global
-        // dependencies.
-        applyImpact(
-            backend.registerInstantiatedClass(superclass, forResolution: true));
-      }
-
-      ClassElement superclass = cls;
-      while (superclass != null) {
-        processClass(superclass);
-        superclass = superclass.superclass;
-      }
+      _universe.registerDynamicUse(dynamicUse, _applyMemberUse);
     });
   }
 
-  void registerDynamicUse(DynamicUse dynamicUse) {
-    task.measure(() {
-      if (_universe.registerDynamicUse(dynamicUse)) {
-        handleUnseenSelector(dynamicUse);
-      }
-    });
-  }
-
-  void processSet(
-      Map<String, Set<Element>> map, String memberName, bool f(Element e)) {
-    Set<Element> members = map[memberName];
-    if (members == null) return;
-    // [f] might add elements to [: map[memberName] :] during the loop below
-    // so we create a new list for [: map[memberName] :] and prepend the
-    // [remaining] members after the loop.
-    map[memberName] = new Set<Element>();
-    Set<Element> remaining = new Set<Element>();
-    for (Element member in members) {
-      if (!f(member)) remaining.add(member);
-    }
-    map[memberName].addAll(remaining);
-  }
-
-  processInstanceMembers(String n, bool f(Element e)) {
-    processSet(instanceMembersByName, n, f);
-  }
-
-  processInstanceFunctions(String n, bool f(Element e)) {
-    processSet(instanceFunctionsByName, n, f);
-  }
-
-  void handleUnseenSelector(DynamicUse universeSelector) {
-    strategy.processDynamicUse(this, universeSelector);
-  }
-
-  void handleUnseenSelectorInternal(DynamicUse dynamicUse) {
-    Selector selector = dynamicUse.selector;
-    String methodName = selector.name;
-    processInstanceMembers(methodName, (Element member) {
-      if (dynamicUse.appliesUnnamed(member, openWorld)) {
-        if (member.isFunction && selector.isGetter) {
-          registerClosurizedMember(member);
-        }
-        addToWorkList(member);
-        return true;
-      }
-      return false;
-    });
-    if (selector.isGetter) {
-      processInstanceFunctions(methodName, (Element member) {
-        if (dynamicUse.appliesUnnamed(member, openWorld)) {
-          registerClosurizedMember(member);
-          return true;
-        }
-        return false;
-      });
-    }
-  }
-
-  /**
-   * Documentation wanted -- johnniwinther
-   *
-   * Invariant: [element] must be a declaration element.
-   */
-  void registerStaticUse(StaticUse staticUse) {
-    strategy.processStaticUse(this, staticUse);
-  }
-
-  void registerStaticUseInternal(StaticUse staticUse) {
+  void processStaticUse(StaticUse staticUse) {
     Element element = staticUse.element;
     assert(invariant(element, element.isDeclaration,
         message: "Element ${element} is not the declaration."));
@@ -453,7 +294,7 @@
         // enqueue.
         LocalFunctionElement closure = staticUse.element;
         if (closure.type.containsTypeVariables) {
-          universe.closuresWithFreeTypeVariables.add(closure);
+          _universe.closuresWithFreeTypeVariables.add(closure);
         }
         addElement = false;
         break;
@@ -479,15 +320,11 @@
         break;
     }
     if (addElement) {
-      addToWorkList(element);
+      _addToWorkList(element);
     }
   }
 
-  void registerTypeUse(TypeUse typeUse) {
-    strategy.processTypeUse(this, typeUse);
-  }
-
-  void registerTypeUseInternal(TypeUse typeUse) {
+  void processTypeUse(TypeUse typeUse) {
     DartType type = typeUse.type;
     switch (typeUse.kind) {
       case TypeUseKind.INSTANTIATION:
@@ -507,7 +344,7 @@
         _registerIsCheck(type);
         break;
       case TypeUseKind.CHECKED_MODE_CHECK:
-        if (options.enableTypeAssertions) {
+        if (_options.enableTypeAssertions) {
           _registerIsCheck(type);
         }
         break;
@@ -517,7 +354,7 @@
   }
 
   void _registerIsCheck(DartType type) {
-    type = _universe.registerIsCheck(type, resolution);
+    type = _universe.registerIsCheck(type, _resolution);
     // Even in checked mode, type annotations for return type and argument
     // types do not imply type checks, so there should never be a check
     // against the type variable of a typedef.
@@ -530,9 +367,9 @@
     _universe.callMethodsWithFreeTypeVariables.add(element);
   }
 
-  void registerClosurizedMember(TypedElement element) {
+  void _registerClosurizedMember(MemberElement element) {
     assert(element.isInstanceMember);
-    if (element.computeType(resolution).containsTypeVariables) {
+    if (element.type.containsTypeVariables) {
       applyImpact(backend.registerClosureWithFreeTypeVariables(element,
           forResolution: true));
       _universe.closuresWithFreeTypeVariables.add(element);
@@ -543,18 +380,20 @@
 
   void forEach(void f(WorkItem work)) {
     do {
-      while (queue.isNotEmpty) {
+      while (_queue.isNotEmpty) {
         // TODO(johnniwinther): Find an optimal process order.
-        WorkItem work = queue.removeLast();
+        WorkItem work = _queue.removeLast();
         if (!isProcessed(work.element)) {
           strategy.processWorkItem(f, work);
           registerProcessedElement(work.element);
         }
       }
-      List recents = recentClasses.toList(growable: false);
-      recentClasses.clear();
-      if (!onQueueEmpty(recents)) recentClasses.addAll(recents);
-    } while (queue.isNotEmpty || recentClasses.isNotEmpty);
+      List recents = _recentClasses.toList(growable: false);
+      _recentClasses.clear();
+      if (!_onQueueEmpty(recents)) {
+        _recentClasses.addAll(recents);
+      }
+    } while (_queue.isNotEmpty || _recentClasses.isNotEmpty);
   }
 
   void logSummary(log(message)) {
@@ -564,20 +403,8 @@
 
   String toString() => 'Enqueuer($name)';
 
-  /// All declaration elements that have been processed by the resolver.
-  final Set<AstElement> processedElements;
-
   Iterable<Entity> get processedEntities => processedElements;
 
-  final Queue<ResolutionWorkItem> queue;
-
-  /// Queue of deferred resolution actions to execute when the resolution queue
-  /// has been emptied.
-  final Queue<_DeferredAction> deferredQueue;
-
-  static const ImpactUseCase IMPACT_USE =
-      const ImpactUseCase('ResolutionEnqueuer');
-
   ImpactUseCase get impactUse => IMPACT_USE;
 
   bool get isResolutionQueue => true;
@@ -595,26 +422,25 @@
     backend.onElementResolved(element);
   }
 
-  /**
-   * Adds [element] to the work list if it has not already been processed.
-   *
-   * Returns [true] if the element was actually added to the queue.
-   */
-  bool internalAddToWorkList(Element element) {
-    if (element.isMalformed) return false;
+  /// Adds [element] to the work list if it has not already been processed.
+  ///
+  /// Invariant: [element] must be a declaration element.
+  void _addToWorkList(Element element) {
+    assert(invariant(element, element.isDeclaration));
+    if (element.isMalformed) return;
 
     assert(invariant(element, element is AnalyzableElement,
         message: 'Element $element is not analyzable.'));
-    if (hasBeenProcessed(element)) return false;
+    if (hasBeenProcessed(element)) return;
     if (queueIsClosed) {
       throw new SpannableAssertionFailure(
           element, "Resolution work list is closed. Trying to add $element.");
     }
 
-    openWorld.registerUsedElement(element);
+    _openWorld.registerUsedElement(element);
 
-    ResolutionWorkItem workItem = resolution.createWorkItem(element);
-    queue.add(workItem);
+    ResolutionWorkItem workItem = _resolution.createWorkItem(element);
+    _queue.add(workItem);
 
     // Enable isolate support if we start using something from the isolate
     // library, or timers for the async library.  We exclude constant fields,
@@ -623,13 +449,13 @@
     if (!universe.hasIsolateSupport && (!element.isField || !element.isConst)) {
       String uri = library.canonicalUri.toString();
       if (uri == 'dart:isolate') {
-        enableIsolateSupport();
+        _enableIsolateSupport();
       } else if (uri == 'dart:async') {
         if (element.name == '_createTimer' ||
             element.name == '_createPeriodicTimer') {
           // The [:Timer:] class uses the event queue of the isolate
           // library, so we make sure that event queue is generated.
-          enableIsolateSupport();
+          _enableIsolateSupport();
         }
       }
     }
@@ -642,18 +468,16 @@
       _universe.hasRuntimeTypeSupport = true;
       // TODO(ahe): Record precise dependency here.
       applyImpact(backend.registerRuntimeType());
-    } else if (commonElements.isFunctionApplyMethod(element)) {
+    } else if (_commonElements.isFunctionApplyMethod(element)) {
       _universe.hasFunctionApplySupport = true;
     }
-
-    return true;
   }
 
-  void registerNoSuchMethod(Element element) {
+  void _registerNoSuchMethod(Element element) {
     backend.registerNoSuchMethod(element);
   }
 
-  void enableIsolateSupport() {
+  void _enableIsolateSupport() {
     _universe.hasIsolateSupport = true;
     applyImpact(backend.enableIsolateSupport(forResolution: true));
   }
@@ -673,16 +497,16 @@
           "Resolution work list is closed. "
           "Trying to add deferred action for $element");
     }
-    deferredQueue.add(new _DeferredAction(element, action));
+    _deferredQueue.add(new _DeferredAction(element, action));
   }
 
-  /// [onQueueEmpty] is called whenever the queue is drained. [recentClasses]
+  /// [_onQueueEmpty] is called whenever the queue is drained. [recentClasses]
   /// contains the set of all classes seen for the first time since
-  /// [onQueueEmpty] was called last. A return value of [true] indicates that
+  /// [_onQueueEmpty] was called last. A return value of [true] indicates that
   /// the [recentClasses] have been processed and may be cleared. If [false] is
-  /// returned, [onQueueEmpty] will be called once the queue is empty again (or
+  /// returned, [_onQueueEmpty] will be called once the queue is empty again (or
   /// still empty) and [recentClasses] will be a superset of the current value.
-  bool onQueueEmpty(Iterable<ClassElement> recentClasses) {
+  bool _onQueueEmpty(Iterable<ClassElement> recentClasses) {
     _emptyDeferredQueue();
 
     return backend.onQueueEmpty(this, recentClasses);
@@ -691,17 +515,14 @@
   void emptyDeferredQueueForTesting() => _emptyDeferredQueue();
 
   void _emptyDeferredQueue() {
-    while (!deferredQueue.isEmpty) {
-      _DeferredAction task = deferredQueue.removeFirst();
-      reporter.withCurrentElement(task.element, task.action);
+    while (!_deferredQueue.isEmpty) {
+      _DeferredAction task = _deferredQueue.removeFirst();
+      _reporter.withCurrentElement(task.element, task.action);
     }
   }
 
   void forgetElement(Element element, Compiler compiler) {
     _universe.forgetElement(element, compiler);
-    _processedClasses.remove(element);
-    instanceMembersByName[element.name]?.remove(element);
-    instanceFunctionsByName[element.name]?.remove(element);
     processedElements.remove(element);
   }
 }
@@ -716,9 +537,6 @@
 class EnqueuerStrategy {
   const EnqueuerStrategy();
 
-  /// Process a class instantiated in live code.
-  void processInstantiatedClass(EnqueuerImpl enqueuer, ClassElement cls) {}
-
   /// Process a static use of and element in live code.
   void processStaticUse(EnqueuerImpl enqueuer, StaticUse staticUse) {}
 
@@ -729,20 +547,7 @@
   void processDynamicUse(EnqueuerImpl enqueuer, DynamicUse dynamicUse) {}
 
   /// Check enqueuer consistency after the queue has been closed.
-  bool checkEnqueuerConsistency(EnqueuerImpl enqueuer) {
-    enqueuer.task.measure(() {
-      // Run through the classes and see if we need to enqueue more methods.
-      for (ClassElement classElement
-          in enqueuer.universe.directlyInstantiatedClasses) {
-        for (ClassElement currentClass = classElement;
-            currentClass != null;
-            currentClass = currentClass.superclass) {
-          enqueuer.processInstantiatedClassMembers(currentClass);
-        }
-      }
-    });
-    return true;
-  }
+  bool checkEnqueuerConsistency(EnqueuerImpl enqueuer) => true;
 
   /// Process [work] using [f].
   void processWorkItem(void f(WorkItem work), WorkItem work) {
@@ -755,7 +560,7 @@
   const DirectEnqueuerStrategy();
   void processStaticUse(EnqueuerImpl enqueuer, StaticUse staticUse) {
     if (staticUse.kind == StaticUseKind.DIRECT_USE) {
-      enqueuer.registerStaticUseInternal(staticUse);
+      enqueuer.processStaticUse(staticUse);
     }
   }
 }
@@ -765,23 +570,34 @@
   const TreeShakingEnqueuerStrategy();
 
   @override
-  void processInstantiatedClass(EnqueuerImpl enqueuer, ClassElement cls) {
-    cls.implementation.forEachMember(enqueuer.processInstantiatedClassMember);
-  }
-
-  @override
   void processStaticUse(EnqueuerImpl enqueuer, StaticUse staticUse) {
-    enqueuer.registerStaticUseInternal(staticUse);
+    enqueuer.processStaticUse(staticUse);
   }
 
   @override
   void processTypeUse(EnqueuerImpl enqueuer, TypeUse typeUse) {
-    enqueuer.registerTypeUseInternal(typeUse);
+    enqueuer.processTypeUse(typeUse);
   }
 
   @override
   void processDynamicUse(EnqueuerImpl enqueuer, DynamicUse dynamicUse) {
-    enqueuer.handleUnseenSelectorInternal(dynamicUse);
+    enqueuer.processDynamicUse(dynamicUse);
+  }
+
+  /// Check enqueuer consistency after the queue has been closed.
+  bool checkEnqueuerConsistency(EnqueuerImpl enqueuer) {
+    enqueuer.task.measure(() {
+      // Run through the classes and see if we need to enqueue more methods.
+      for (ClassElement classElement
+          in enqueuer.universe.directlyInstantiatedClasses) {
+        for (ClassElement currentClass = classElement;
+            currentClass != null;
+            currentClass = currentClass.superclass) {
+          enqueuer.checkClass(currentClass);
+        }
+      }
+    });
+    return true;
   }
 }
 
@@ -792,17 +608,17 @@
 
   @override
   void visitDynamicUse(DynamicUse dynamicUse) {
-    enqueuer.registerDynamicUse(dynamicUse);
+    enqueuer.strategy.processDynamicUse(enqueuer, dynamicUse);
   }
 
   @override
   void visitStaticUse(StaticUse staticUse) {
-    enqueuer.registerStaticUse(staticUse);
+    enqueuer.strategy.processStaticUse(enqueuer, staticUse);
   }
 
   @override
   void visitTypeUse(TypeUse typeUse) {
-    enqueuer.registerTypeUse(typeUse);
+    enqueuer.strategy.processTypeUse(enqueuer, typeUse);
   }
 }
 
diff --git a/pkg/compiler/lib/src/js_backend/backend.dart b/pkg/compiler/lib/src/js_backend/backend.dart
index c4d156b..811096b 100644
--- a/pkg/compiler/lib/src/js_backend/backend.dart
+++ b/pkg/compiler/lib/src/js_backend/backend.dart
@@ -748,6 +748,10 @@
         element == coreClasses.stringClass) {
       // TODO(johnniwinther): Avoid these.
       return true;
+    } else if (element == helpers.genericNoSuchMethod ||
+        element == helpers.unresolvedConstructorError ||
+        element == helpers.malformedTypeError) {
+      return true;
     }
     return false;
   }
diff --git a/pkg/compiler/lib/src/js_backend/backend_helpers.dart b/pkg/compiler/lib/src/js_backend/backend_helpers.dart
index e50c744..ee8d696 100644
--- a/pkg/compiler/lib/src/js_backend/backend_helpers.dart
+++ b/pkg/compiler/lib/src/js_backend/backend_helpers.dart
@@ -215,6 +215,9 @@
     return element;
   }
 
+  Element findCoreHelper(String name) =>
+      compiler.commonElements.coreLibrary.implementation.localLookup(name);
+
   ConstructorElement _findConstructor(ClassElement cls, String name) {
     cls.ensureResolved(resolution);
     ConstructorElement constructor = cls.lookupConstructor(name);
@@ -633,6 +636,18 @@
     return findHelper('throwNoSuchMethod');
   }
 
+  Element get genericNoSuchMethod =>
+      _genericNoSuchMethod ??= findCoreHelper('_genericNoSuchMethod');
+  MethodElement _genericNoSuchMethod;
+
+  Element get unresolvedConstructorError => _unresolvedConstructorError ??=
+      findCoreHelper('_unresolvedConstructorError');
+  MethodElement _unresolvedConstructorError;
+
+  Element get malformedTypeError =>
+      _malformedTypeError ??= findCoreHelper('_malformedTypeError');
+  MethodElement _malformedTypeError;
+
   Element get createRuntimeType {
     return findHelper('createRuntimeType');
   }
diff --git a/pkg/compiler/lib/src/js_backend/backend_impact.dart b/pkg/compiler/lib/src/js_backend/backend_impact.dart
index b5b9e72..7b12839 100644
--- a/pkg/compiler/lib/src/js_backend/backend_impact.dart
+++ b/pkg/compiler/lib/src/js_backend/backend_impact.dart
@@ -160,13 +160,21 @@
   BackendImpact _throwNoSuchMethod;
 
   BackendImpact get throwNoSuchMethod {
-    return _throwNoSuchMethod ??= new BackendImpact(staticUses: [
-      helpers.throwNoSuchMethod
-    ], otherImpacts: [
-      // Also register the types of the arguments passed to this method.
-      _needsList('Needed to encode the arguments for throw NoSuchMethodError.'),
-      _needsString('Needed to encode the name for throw NoSuchMethodError.')
-    ]);
+    return _throwNoSuchMethod ??= new BackendImpact(
+        staticUses: compiler.options.useKernel
+            ? [
+                helpers.genericNoSuchMethod,
+                helpers.unresolvedConstructorError,
+              ]
+            : [
+                helpers.throwNoSuchMethod,
+              ],
+        otherImpacts: [
+          // Also register the types of the arguments passed to this method.
+          _needsList(
+              'Needed to encode the arguments for throw NoSuchMethodError.'),
+          _needsString('Needed to encode the name for throw NoSuchMethodError.')
+        ]);
   }
 
   BackendImpact _stringValues;
@@ -427,8 +435,14 @@
   BackendImpact _malformedTypeCheck;
 
   BackendImpact get malformedTypeCheck {
-    return _malformedTypeCheck ??=
-        new BackendImpact(staticUses: [helpers.throwTypeError]);
+    return _malformedTypeCheck ??= new BackendImpact(
+        staticUses: compiler.options.useKernel
+            ? [
+                helpers.malformedTypeError,
+              ]
+            : [
+                helpers.throwTypeError,
+              ]);
   }
 
   BackendImpact _genericTypeCheck;
diff --git a/pkg/compiler/lib/src/js_backend/enqueuer.dart b/pkg/compiler/lib/src/js_backend/enqueuer.dart
index c0b028c..e51a5fa 100644
--- a/pkg/compiler/lib/src/js_backend/enqueuer.dart
+++ b/pkg/compiler/lib/src/js_backend/enqueuer.dart
@@ -48,12 +48,12 @@
   @deprecated
   final Compiler _compiler; // TODO(ahe): Remove this dependency.
   final EnqueuerStrategy strategy;
-  final Map<String, Set<Element>> instanceMembersByName =
+  final Map<String, Set<Element>> _instanceMembersByName =
       new Map<String, Set<Element>>();
-  final Map<String, Set<Element>> instanceFunctionsByName =
+  final Map<String, Set<Element>> _instanceFunctionsByName =
       new Map<String, Set<Element>>();
   final Set<ClassElement> _processedClasses = new Set<ClassElement>();
-  Set<ClassElement> recentClasses = new Setlet<ClassElement>();
+  Set<ClassElement> _recentClasses = new Setlet<ClassElement>();
   final CodegenWorldBuilderImpl _universe =
       new CodegenWorldBuilderImpl(const TypeMaskStrategy());
 
@@ -61,23 +61,34 @@
   final CompilerTask task;
   final native.NativeEnqueuer nativeEnqueuer;
 
-  WorldImpactVisitor impactVisitor;
+  WorldImpactVisitor _impactVisitor;
+
+  final Queue<WorkItem> queue = new Queue<WorkItem>();
+  final Map<Element, js.Expression> generatedCode = <Element, js.Expression>{};
+
+  final Set<Element> newlyEnqueuedElements;
+
+  final Set<DynamicUse> newlySeenSelectors;
+
+  bool _enabledNoSuchMethod = false;
+
+  static const ImpactUseCase IMPACT_USE =
+      const ImpactUseCase('CodegenEnqueuer');
 
   CodegenEnqueuer(this.task, Compiler compiler, this.strategy)
-      : queue = new Queue<CodegenWorkItem>(),
-        newlyEnqueuedElements = compiler.cacheStrategy.newSet(),
+      : newlyEnqueuedElements = compiler.cacheStrategy.newSet(),
         newlySeenSelectors = compiler.cacheStrategy.newSet(),
         nativeEnqueuer = compiler.backend.nativeCodegenEnqueuer(),
         this.name = 'codegen enqueuer',
         this._compiler = compiler {
-    impactVisitor = new EnqueuerImplImpactVisitor(this);
+    _impactVisitor = new EnqueuerImplImpactVisitor(this);
   }
 
   CodegenWorldBuilder get universe => _universe;
 
-  Backend get backend => _compiler.backend;
+  Backend get _backend => _compiler.backend;
 
-  CompilerOptions get options => _compiler.options;
+  CompilerOptions get _options => _compiler.options;
 
   ClosedWorld get _world => _compiler.closedWorld;
 
@@ -86,27 +97,26 @@
   /// Returns [:true:] if this enqueuer is the resolution enqueuer.
   bool get isResolutionQueue => false;
 
-  DiagnosticReporter get reporter => _compiler.reporter;
-
   /**
    * Documentation wanted -- johnniwinther
    *
    * Invariant: [element] must be a declaration element.
    */
-  void addToWorkList(Element element) {
+  void _addToWorkList(Element element) {
     assert(invariant(element, element.isDeclaration));
     // Don't generate code for foreign elements.
-    if (backend.isForeign(element)) return;
+    if (_backend.isForeign(element)) return;
 
     // Codegen inlines field initializers. It only needs to generate
     // code for checked setters.
     if (element.isField && element.isInstanceMember) {
-      if (!options.enableTypeAssertions || element.enclosingElement.isClosure) {
+      if (!_options.enableTypeAssertions ||
+          element.enclosingElement.isClosure) {
         return;
       }
     }
 
-    if (options.hasIncrementalSupport && !isProcessed(element)) {
+    if (_options.hasIncrementalSupport && !isProcessed(element)) {
       newlyEnqueuedElements.add(element);
     }
 
@@ -114,7 +124,7 @@
       throw new SpannableAssertionFailure(
           element, "Codegen work list is closed. Trying to add $element");
     }
-    queue.add(new CodegenWorkItem(backend, element));
+    queue.add(new CodegenWorkItem(_backend, element));
     // TODO(sigmund): add other missing dependencies (internals, selectors
     // enqueued after allocations).
     _compiler.dumpInfoTask
@@ -124,31 +134,27 @@
   void applyImpact(WorldImpact worldImpact, {Element impactSource}) {
     if (worldImpact.isEmpty) return;
     impactStrategy.visitImpact(
-        impactSource, worldImpact, impactVisitor, impactUse);
-  }
-
-  void registerInstantiatedType(InterfaceType type) {
-    _registerInstantiatedType(type);
+        impactSource, worldImpact, _impactVisitor, impactUse);
   }
 
   void _registerInstantiatedType(InterfaceType type,
       {bool mirrorUsage: false, bool nativeUsage: false}) {
     task.measure(() {
       ClassElement cls = type.element;
-      bool isNative = backend.isNative(cls);
+      bool isNative = _backend.isNative(cls);
       _universe.registerTypeInstantiation(type,
           isNative: isNative,
           byMirrors: mirrorUsage, onImplemented: (ClassElement cls) {
         applyImpact(
-            backend.registerImplementedClass(cls, forResolution: false));
+            _backend.registerImplementedClass(cls, forResolution: false));
       });
       if (nativeUsage) {
         nativeEnqueuer.onInstantiatedType(type);
       }
-      backend.registerInstantiatedType(type);
+      _backend.registerInstantiatedType(type);
       // TODO(johnniwinther): Share this reasoning with [Universe].
       if (!cls.isAbstract || isNative || mirrorUsage) {
-        processInstantiatedClass(cls);
+        _processInstantiatedClass(cls);
       }
     });
   }
@@ -157,8 +163,8 @@
     return strategy.checkEnqueuerConsistency(this);
   }
 
-  void processInstantiatedClassMembers(ClassElement cls) {
-    strategy.processInstantiatedClass(this, cls);
+  void checkClass(ClassElement cls) {
+    cls.implementation.forEachMember(processInstantiatedClassMember);
   }
 
   void processInstantiatedClassMember(ClassElement cls, Element member) {
@@ -175,13 +181,13 @@
       // its metadata parsed and analyzed.
       // Note: this assumes that there are no non-native fields on native
       // classes, which may not be the case when a native class is subclassed.
-      if (backend.isNative(cls)) {
+      if (_backend.isNative(cls)) {
         if (_universe.hasInvokedGetter(member, _world) ||
             _universe.hasInvocation(member, _world)) {
-          addToWorkList(member);
+          _addToWorkList(member);
           return;
         } else if (universe.hasInvokedSetter(member, _world)) {
-          addToWorkList(member);
+          _addToWorkList(member);
           return;
         }
         // Native fields need to go into instanceMembersByName as they
@@ -190,52 +196,52 @@
         // All field initializers must be resolved as they could
         // have an observable side-effect (and cannot be tree-shaken
         // away).
-        addToWorkList(member);
+        _addToWorkList(member);
         return;
       }
     } else if (member.isFunction) {
       FunctionElement function = member;
       if (function.name == Identifiers.noSuchMethod_) {
-        registerNoSuchMethod(function);
+        _registerNoSuchMethod(function);
       }
       if (function.name == Identifiers.call && !cls.typeVariables.isEmpty) {
-        registerCallMethodWithFreeTypeVariables(function);
+        _registerCallMethodWithFreeTypeVariables(function);
       }
       // If there is a property access with the same name as a method we
       // need to emit the method.
       if (_universe.hasInvokedGetter(function, _world)) {
-        registerClosurizedMember(function);
-        addToWorkList(function);
+        _registerClosurizedMember(function);
+        _addToWorkList(function);
         return;
       }
       _registerInstanceMethod(function);
       if (_universe.hasInvocation(function, _world)) {
-        addToWorkList(function);
+        _addToWorkList(function);
         return;
       }
     } else if (member.isGetter) {
       FunctionElement getter = member;
       if (_universe.hasInvokedGetter(getter, _world)) {
-        addToWorkList(getter);
+        _addToWorkList(getter);
         return;
       }
       // We don't know what selectors the returned closure accepts. If
       // the set contains any selector we have to assume that it matches.
       if (_universe.hasInvocation(getter, _world)) {
-        addToWorkList(getter);
+        _addToWorkList(getter);
         return;
       }
     } else if (member.isSetter) {
       FunctionElement setter = member;
       if (_universe.hasInvokedSetter(setter, _world)) {
-        addToWorkList(setter);
+        _addToWorkList(setter);
         return;
       }
     }
 
     // The element is not yet used. Add it to the list of instance
     // members to still be processed.
-    instanceMembersByName
+    _instanceMembersByName
         .putIfAbsent(memberName, () => new Set<Element>())
         .add(member);
   }
@@ -243,14 +249,12 @@
   // Store the member in [instanceFunctionsByName] to catch
   // getters on the function.
   void _registerInstanceMethod(MethodElement element) {
-    instanceFunctionsByName
+    _instanceFunctionsByName
         .putIfAbsent(element.name, () => new Set<Element>())
         .add(element);
   }
 
-  void enableIsolateSupport() {}
-
-  void processInstantiatedClass(ClassElement cls) {
+  void _processInstantiatedClass(ClassElement cls) {
     task.measure(() {
       if (_processedClasses.contains(cls)) return;
 
@@ -266,12 +270,12 @@
         */
 
         _processedClasses.add(superclass);
-        recentClasses.add(superclass);
+        _recentClasses.add(superclass);
         superclass.implementation.forEachMember(processInstantiatedClassMember);
         // We only tell the backend once that [superclass] was instantiated, so
         // any additional dependencies must be treated as global
         // dependencies.
-        applyImpact(backend.registerInstantiatedClass(superclass,
+        applyImpact(_backend.registerInstantiatedClass(superclass,
             forResolution: false));
       }
 
@@ -283,15 +287,15 @@
     });
   }
 
-  void registerDynamicUse(DynamicUse dynamicUse) {
+  void processDynamicUse(DynamicUse dynamicUse) {
     task.measure(() {
       if (_universe.registerDynamicUse(dynamicUse)) {
-        handleUnseenSelector(dynamicUse);
+        _handleUnseenSelector(dynamicUse);
       }
     });
   }
 
-  void processSet(
+  void _processSet(
       Map<String, Set<Element>> map, String memberName, bool f(Element e)) {
     Set<Element> members = map[memberName];
     if (members == null) return;
@@ -306,35 +310,34 @@
     map[memberName].addAll(remaining);
   }
 
-  processInstanceMembers(String n, bool f(Element e)) {
-    processSet(instanceMembersByName, n, f);
+  void _processInstanceMembers(String n, bool f(Element e)) {
+    _processSet(_instanceMembersByName, n, f);
   }
 
-  processInstanceFunctions(String n, bool f(Element e)) {
-    processSet(instanceFunctionsByName, n, f);
+  void _processInstanceFunctions(String n, bool f(Element e)) {
+    _processSet(_instanceFunctionsByName, n, f);
   }
 
-  void _handleUnseenSelector(DynamicUse universeSelector) {
-    strategy.processDynamicUse(this, universeSelector);
-  }
-
-  void handleUnseenSelectorInternal(DynamicUse dynamicUse) {
+  void _handleUnseenSelector(DynamicUse dynamicUse) {
+    if (_options.hasIncrementalSupport) {
+      newlySeenSelectors.add(dynamicUse);
+    }
     Selector selector = dynamicUse.selector;
     String methodName = selector.name;
-    processInstanceMembers(methodName, (Element member) {
+    _processInstanceMembers(methodName, (Element member) {
       if (dynamicUse.appliesUnnamed(member, _world)) {
         if (member.isFunction && selector.isGetter) {
-          registerClosurizedMember(member);
+          _registerClosurizedMember(member);
         }
-        addToWorkList(member);
+        _addToWorkList(member);
         return true;
       }
       return false;
     });
     if (selector.isGetter) {
-      processInstanceFunctions(methodName, (Element member) {
+      _processInstanceFunctions(methodName, (Element member) {
         if (dynamicUse.appliesUnnamed(member, _world)) {
-          registerClosurizedMember(member);
+          _registerClosurizedMember(member);
           return true;
         }
         return false;
@@ -342,25 +345,16 @@
     }
   }
 
-  /**
-   * Documentation wanted -- johnniwinther
-   *
-   * Invariant: [element] must be a declaration element.
-   */
-  void registerStaticUse(StaticUse staticUse) {
-    strategy.processStaticUse(this, staticUse);
-  }
-
-  void registerStaticUseInternal(StaticUse staticUse) {
+  void processStaticUse(StaticUse staticUse) {
     Element element = staticUse.element;
     assert(invariant(element, element.isDeclaration,
         message: "Element ${element} is not the declaration."));
     _universe.registerStaticUse(staticUse);
-    applyImpact(backend.registerStaticUse(element, forResolution: false));
+    applyImpact(_backend.registerStaticUse(element, forResolution: false));
     bool addElement = true;
     switch (staticUse.kind) {
       case StaticUseKind.STATIC_TEAR_OFF:
-        applyImpact(backend.registerGetOfStaticFunction());
+        applyImpact(_backend.registerGetOfStaticFunction());
         break;
       case StaticUseKind.FIELD_GET:
       case StaticUseKind.FIELD_SET:
@@ -379,22 +373,18 @@
       case StaticUseKind.CONSTRUCTOR_INVOKE:
       case StaticUseKind.CONST_CONSTRUCTOR_INVOKE:
       case StaticUseKind.REDIRECTION:
-        registerTypeUseInternal(new TypeUse.instantiation(staticUse.type));
+        processTypeUse(new TypeUse.instantiation(staticUse.type));
         break;
       case StaticUseKind.DIRECT_INVOKE:
         _registerInstanceMethod(staticUse.element);
         break;
     }
     if (addElement) {
-      addToWorkList(element);
+      _addToWorkList(element);
     }
   }
 
-  void registerTypeUse(TypeUse typeUse) {
-    strategy.processTypeUse(this, typeUse);
-  }
-
-  void registerTypeUseInternal(TypeUse typeUse) {
+  void processTypeUse(TypeUse typeUse) {
     DartType type = typeUse.type;
     switch (typeUse.kind) {
       case TypeUseKind.INSTANTIATION:
@@ -412,7 +402,7 @@
         _registerIsCheck(type);
         break;
       case TypeUseKind.CHECKED_MODE_CHECK:
-        if (options.enableTypeAssertions) {
+        if (_options.enableTypeAssertions) {
           _registerIsCheck(type);
         }
         break;
@@ -429,18 +419,18 @@
     assert(!type.isTypeVariable || !type.element.enclosingElement.isTypedef);
   }
 
-  void registerCallMethodWithFreeTypeVariables(Element element) {
-    applyImpact(backend.registerCallMethodWithFreeTypeVariables(element,
+  void _registerCallMethodWithFreeTypeVariables(Element element) {
+    applyImpact(_backend.registerCallMethodWithFreeTypeVariables(element,
         forResolution: false));
   }
 
-  void registerClosurizedMember(TypedElement element) {
+  void _registerClosurizedMember(TypedElement element) {
     assert(element.isInstanceMember);
     if (element.type.containsTypeVariables) {
-      applyImpact(backend.registerClosureWithFreeTypeVariables(element,
+      applyImpact(_backend.registerClosureWithFreeTypeVariables(element,
           forResolution: false));
     }
-    applyImpact(backend.registerBoundClosure());
+    applyImpact(_backend.registerBoundClosure());
   }
 
   void forEach(void f(WorkItem work)) {
@@ -454,24 +444,24 @@
           // is currently a side-effect of calling `work.run`.
         }
       }
-      List recents = recentClasses.toList(growable: false);
-      recentClasses.clear();
-      if (!onQueueEmpty(recents)) recentClasses.addAll(recents);
-    } while (queue.isNotEmpty || recentClasses.isNotEmpty);
+      List recents = _recentClasses.toList(growable: false);
+      _recentClasses.clear();
+      if (!_onQueueEmpty(recents)) _recentClasses.addAll(recents);
+    } while (queue.isNotEmpty || _recentClasses.isNotEmpty);
   }
 
-  /// [onQueueEmpty] is called whenever the queue is drained. [recentClasses]
+  /// [_onQueueEmpty] is called whenever the queue is drained. [recentClasses]
   /// contains the set of all classes seen for the first time since
-  /// [onQueueEmpty] was called last. A return value of [true] indicates that
+  /// [_onQueueEmpty] was called last. A return value of [true] indicates that
   /// the [recentClasses] have been processed and may be cleared. If [false] is
-  /// returned, [onQueueEmpty] will be called once the queue is empty again (or
+  /// returned, [_onQueueEmpty] will be called once the queue is empty again (or
   /// still empty) and [recentClasses] will be a superset of the current value.
-  bool onQueueEmpty(Iterable<ClassElement> recentClasses) {
-    return backend.onQueueEmpty(this, recentClasses);
+  bool _onQueueEmpty(Iterable<ClassElement> recentClasses) {
+    return _backend.onQueueEmpty(this, recentClasses);
   }
 
   void logSummary(log(message)) {
-    _logSpecificSummary(log);
+    log('Compiled ${generatedCode.length} methods.');
     nativeEnqueuer.logSummary(log);
   }
 
@@ -480,57 +470,34 @@
   void _forgetElement(Element element) {
     _universe.forgetElement(element, _compiler);
     _processedClasses.remove(element);
-    instanceMembersByName[element.name]?.remove(element);
-    instanceFunctionsByName[element.name]?.remove(element);
+    _instanceMembersByName[element.name]?.remove(element);
+    _instanceFunctionsByName[element.name]?.remove(element);
   }
 
-  final Queue<CodegenWorkItem> queue;
-  final Map<Element, js.Expression> generatedCode = <Element, js.Expression>{};
-
-  final Set<Element> newlyEnqueuedElements;
-
-  final Set<DynamicUse> newlySeenSelectors;
-
-  bool enabledNoSuchMethod = false;
-
-  static const ImpactUseCase IMPACT_USE =
-      const ImpactUseCase('CodegenEnqueuer');
-
   ImpactUseCase get impactUse => IMPACT_USE;
 
   bool isProcessed(Element member) =>
       member.isAbstract || generatedCode.containsKey(member);
 
-  void registerNoSuchMethod(Element element) {
-    if (!enabledNoSuchMethod && backend.enabledNoSuchMethod) {
-      applyImpact(backend.enableNoSuchMethod());
-      enabledNoSuchMethod = true;
+  void _registerNoSuchMethod(Element element) {
+    if (!_enabledNoSuchMethod && _backend.enabledNoSuchMethod) {
+      applyImpact(_backend.enableNoSuchMethod());
+      _enabledNoSuchMethod = true;
     }
   }
 
-  void _logSpecificSummary(log(message)) {
-    log('Compiled ${generatedCode.length} methods.');
-  }
-
   void forgetElement(Element element, Compiler compiler) {
     _forgetElement(element);
     generatedCode.remove(element);
     if (element is MemberElement) {
       for (Element closure in element.nestedClosures) {
         generatedCode.remove(closure);
-        removeFromSet(instanceMembersByName, closure);
-        removeFromSet(instanceFunctionsByName, closure);
+        removeFromSet(_instanceMembersByName, closure);
+        removeFromSet(_instanceFunctionsByName, closure);
       }
     }
   }
 
-  void handleUnseenSelector(DynamicUse dynamicUse) {
-    if (options.hasIncrementalSupport) {
-      newlySeenSelectors.add(dynamicUse);
-    }
-    _handleUnseenSelector(dynamicUse);
-  }
-
   @override
   Iterable<Entity> get processedEntities => generatedCode.keys;
 
diff --git a/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart b/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart
index 9956a18..a318872 100644
--- a/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart
+++ b/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart
@@ -267,4 +267,9 @@
   }
 }
 
-enum NsmCategory { DEFAULT, THROWING, NOT_APPLICABLE, OTHER, }
+enum NsmCategory {
+  DEFAULT,
+  THROWING,
+  NOT_APPLICABLE,
+  OTHER,
+}
diff --git a/pkg/compiler/lib/src/js_backend/patch_resolver.dart b/pkg/compiler/lib/src/js_backend/patch_resolver.dart
index 17a4a4e..10f30c5 100644
--- a/pkg/compiler/lib/src/js_backend/patch_resolver.dart
+++ b/pkg/compiler/lib/src/js_backend/patch_resolver.dart
@@ -106,10 +106,24 @@
   void checkMatchingPatchSignatures(
       FunctionElement origin, FunctionElement patch) {
     // TODO(johnniwinther): Show both origin and patch locations on errors.
+    FunctionExpression originTree = origin.node;
     FunctionSignature originSignature = origin.functionSignature;
     FunctionExpression patchTree = patch.node;
     FunctionSignature patchSignature = patch.functionSignature;
 
+    if ('${originTree.typeVariables}' != '${patchTree.typeVariables}') {
+      reporter.withCurrentElement(patch, () {
+        Node errorNode = patchTree.typeVariables != null
+            ? patchTree.typeVariables
+            : patchTree;
+        reporter.reportError(
+            reporter.createMessage(
+                errorNode,
+                MessageKind.PATCH_TYPE_VARIABLES_MISMATCH,
+                {'methodName': origin.name}),
+            [reporter.createMessage(origin, MessageKind.THIS_IS_THE_METHOD)]);
+      });
+    }
     if (originSignature.type.returnType != patchSignature.type.returnType) {
       reporter.withCurrentElement(patch, () {
         Node errorNode =
diff --git a/pkg/compiler/lib/src/js_emitter/full_emitter/setup_program_builder.dart b/pkg/compiler/lib/src/js_emitter/full_emitter/setup_program_builder.dart
index feaee8e..95c7dc4 100644
--- a/pkg/compiler/lib/src/js_emitter/full_emitter/setup_program_builder.dart
+++ b/pkg/compiler/lib/src/js_emitter/full_emitter/setup_program_builder.dart
@@ -499,6 +499,7 @@
           chain = targetPrototype.#deferredAction;
         }
         return function foo() {
+          if (!supportsDirectProtoAccess) return;
           var prototype = this;
           // Find the actual prototype that this handler is installed on.
           while (!prototype.hasOwnProperty(#deferredActionString)) {
diff --git a/pkg/compiler/lib/src/kernel/kernel.dart b/pkg/compiler/lib/src/kernel/kernel.dart
index 1210501..77c7e2b 100644
--- a/pkg/compiler/lib/src/kernel/kernel.dart
+++ b/pkg/compiler/lib/src/kernel/kernel.dart
@@ -11,7 +11,8 @@
 import '../common.dart';
 import '../common/names.dart';
 import '../compiler.dart' show Compiler;
-import '../constants/expressions.dart' show TypeConstantExpression;
+import '../constants/expressions.dart'
+    show ConstantExpression, TypeConstantExpression;
 import '../dart_types.dart'
     show DartType, FunctionType, InterfaceType, TypeKind, TypeVariableType;
 import '../diagnostics/messages.dart' show MessageKind;
@@ -74,6 +75,13 @@
   final Map<ir.Node, Element> nodeToElement = <ir.Node, Element>{};
   final Map<ir.Node, Node> nodeToAst = <ir.Node, Node>{};
   final Map<ir.Node, Node> nodeToAstOperator = <ir.Node, Node>{};
+  // Synthetic nodes are nodes we generated that do not correspond to
+  // [ast.Node]s. A node should be in one of nodeToAst or syntheticNodes but not
+  // both.
+  final Set<ir.Node> syntheticNodes = new Set<ir.Node>();
+
+  final Map<ir.Node, ConstantExpression> parameterInitializerNodeToConstant =
+      <ir.Node, ConstantExpression>{};
 
   /// FIFO queue of work that needs to be completed before the returned AST
   /// nodes are correct.
diff --git a/pkg/compiler/lib/src/kernel/kernel_visitor.dart b/pkg/compiler/lib/src/kernel/kernel_visitor.dart
index 664388d..37d813e 100644
--- a/pkg/compiler/lib/src/kernel/kernel_visitor.dart
+++ b/pkg/compiler/lib/src/kernel/kernel_visitor.dart
@@ -2019,6 +2019,8 @@
         if (initializer != null) {
           variable.initializer = initializer;
           initializer.parent = variable;
+          kernel.parameterInitializerNodeToConstant[initializer] =
+              parameter.constant;
         }
       });
       if (function.isGenerativeConstructor) {
diff --git a/pkg/compiler/lib/src/kernel/task.dart b/pkg/compiler/lib/src/kernel/task.dart
index 59cf0b4..42f439b 100644
--- a/pkg/compiler/lib/src/kernel/task.dart
+++ b/pkg/compiler/lib/src/kernel/task.dart
@@ -29,8 +29,8 @@
   ///
   /// May enqueue more elements to the resolution queue.
   void buildKernelIr() => measure(() {
-    program = buildProgram(_compiler.mainApp);
-  });
+        program = buildProgram(_compiler.mainApp);
+      });
 
   /// Builds the kernel IR program for the main function exported from
   /// [library].
diff --git a/pkg/compiler/lib/src/kernel/unresolved.dart b/pkg/compiler/lib/src/kernel/unresolved.dart
index 04632b7..49e2b3d 100644
--- a/pkg/compiler/lib/src/kernel/unresolved.dart
+++ b/pkg/compiler/lib/src/kernel/unresolved.dart
@@ -57,11 +57,15 @@
   ir.Expression buildThrowNoSuchMethodError(ir.Procedure exceptionBuilder,
       ir.Expression receiver, String memberName, ir.Arguments callArguments,
       [Element candidateTarget]) {
-    ir.Expression memberNameArg = new ir.SymbolLiteral(memberName);
-    ir.Expression positional = new ir.ListLiteral(callArguments.positional);
-    ir.Expression named = new ir.MapLiteral(callArguments.named.map((e) {
-      return new ir.MapEntry(new ir.SymbolLiteral(e.name), e.value);
-    }).toList());
+    ir.Expression memberNameArg =
+        markSynthetic(new ir.SymbolLiteral(memberName));
+    ir.Expression positional =
+        markSynthetic(new ir.ListLiteral(callArguments.positional));
+    ir.Expression named =
+        markSynthetic(new ir.MapLiteral(callArguments.named.map((e) {
+      return new ir.MapEntry(
+          markSynthetic(new ir.SymbolLiteral(e.name)), e.value);
+    }).toList()));
     if (candidateTarget is FunctionElement) {
       // Ensure [candidateTarget] has been resolved.
       possiblyErroneousFunctionToIr(candidateTarget);
@@ -72,13 +76,15 @@
         candidateTarget.hasFunctionSignature) {
       List<ir.Expression> existingArgumentsList = <ir.Expression>[];
       candidateTarget.functionSignature.forEachParameter((param) {
-        existingArgumentsList.add(new ir.StringLiteral(param.name));
+        existingArgumentsList
+            .add(markSynthetic(new ir.StringLiteral(param.name)));
       });
-      existingArguments = new ir.ListLiteral(existingArgumentsList);
+      existingArguments =
+          markSynthetic(new ir.ListLiteral(existingArgumentsList));
     } else {
       existingArguments = new ir.NullLiteral();
     }
-    return new ir.Throw(new ir.StaticInvocation(
+    ir.Expression construction = markSynthetic(new ir.StaticInvocation(
         exceptionBuilder,
         new ir.Arguments(<ir.Expression>[
           receiver,
@@ -87,6 +93,12 @@
           named,
           existingArguments
         ])));
+    return new ir.Throw(construction);
+  }
+
+  ir.Expression markSynthetic(ir.Expression expression) {
+    kernel.syntheticNodes.add(expression);
+    return expression;
   }
 
   /// Throws a NoSuchMethodError for an unresolved getter named [name].
diff --git a/pkg/compiler/lib/src/library_loader.dart b/pkg/compiler/lib/src/library_loader.dart
index c7c6e86..796b707 100644
--- a/pkg/compiler/lib/src/library_loader.dart
+++ b/pkg/compiler/lib/src/library_loader.dart
@@ -427,7 +427,8 @@
       // TODO(johnniwinther): Ensure that currentHandler correctly encloses the
       // loading of a library cluster.
       currentHandler = new LibraryDependencyHandler(this);
-      return createLibrary(currentHandler, null, resolvedUri,
+      return createLibrary(
+              currentHandler, null, resolvedUri, NO_LOCATION_SPANNABLE,
               skipFileWithPartOfTag: skipFileWithPartOfTag)
           .then((LibraryElement library) {
         if (library == null) {
@@ -543,7 +544,7 @@
 
         // Import dart:core if not already imported.
         if (!importsDartCore && library.canonicalUri != Uris.dart_core) {
-          return createLibrary(handler, null, Uris.dart_core)
+          return createLibrary(handler, null, Uris.dart_core, library)
               .then((LibraryElement coreLibrary) {
             handler.registerDependency(
                 library,
@@ -629,7 +630,7 @@
       LibraryElement library, LibraryDependencyElementX libraryDependency) {
     Uri base = library.canonicalUri;
     Uri resolvedUri = base.resolveUri(libraryDependency.uri);
-    return createLibrary(handler, library, resolvedUri, node: libraryDependency)
+    return createLibrary(handler, library, resolvedUri, libraryDependency)
         .then((LibraryElement loadedLibrary) {
       if (loadedLibrary == null) return;
       reporter.withCurrentElement(library, () {
@@ -650,15 +651,15 @@
     return listener.onLibraryScanned(library, handler).then((_) {
       return Future.forEach(library.imports, (ImportElement import) {
         Uri resolvedUri = library.canonicalUri.resolveUri(import.uri);
-        return createLibrary(handler, library, resolvedUri);
+        return createLibrary(handler, library, resolvedUri, library);
       }).then((_) {
         return Future.forEach(library.exports, (ExportElement export) {
           Uri resolvedUri = library.canonicalUri.resolveUri(export.uri);
-          return createLibrary(handler, library, resolvedUri);
+          return createLibrary(handler, library, resolvedUri, library);
         }).then((_) {
           // TODO(johnniwinther): Shouldn't there be an [ImportElement] for the
           // implicit import of dart:core?
-          return createLibrary(handler, library, Uris.dart_core);
+          return createLibrary(handler, library, Uris.dart_core, library);
         }).then((_) => library);
       });
     });
@@ -680,10 +681,10 @@
    * If a new library is created, the [handler] is notified.
    */
   Future<LibraryElement> createLibrary(LibraryDependencyHandler handler,
-      LibraryElement importingLibrary, Uri resolvedUri,
-      {Spannable node, bool skipFileWithPartOfTag: false}) {
+      LibraryElement importingLibrary, Uri resolvedUri, Spannable spannable,
+      {bool skipFileWithPartOfTag: false}) {
     Uri readableUri =
-        uriTranslator.translate(importingLibrary, resolvedUri, node);
+        uriTranslator.translate(importingLibrary, resolvedUri, spannable);
     LibraryElement library = libraryCanonicalUriMap[resolvedUri];
     if (library != null) {
       return new Future.value(library);
@@ -693,7 +694,7 @@
         return loadDeserializedLibrary(handler, library);
       }
       return reporter.withCurrentElement(importingLibrary, () {
-        return _readScript(node, readableUri, resolvedUri)
+        return _readScript(spannable, readableUri, resolvedUri)
             .then((Script script) {
           if (script == null) return null;
           LibraryElement element =
@@ -721,7 +722,7 @@
               DiagnosticMessage info = reporter.withCurrentElement(
                   importingLibrary,
                   () => reporter.createMessage(
-                      node, MessageKind.IMPORT_PART_OF_HERE));
+                      spannable, MessageKind.IMPORT_PART_OF_HERE));
               reporter.reportError(error, [info]);
             }
           }
diff --git a/pkg/compiler/lib/src/parser/class_element_parser.dart b/pkg/compiler/lib/src/parser/class_element_parser.dart
index 851873a..88a6fa1 100644
--- a/pkg/compiler/lib/src/parser/class_element_parser.dart
+++ b/pkg/compiler/lib/src/parser/class_element_parser.dart
@@ -9,7 +9,7 @@
 import 'partial_parser.dart' show PartialParser;
 
 class ClassElementParser extends PartialParser {
-  ClassElementParser(Listener listener): super(listener);
+  ClassElementParser(Listener listener) : super(listener);
 
   Token parseClassBody(Token token) => fullParseClassBody(token);
 }
diff --git a/pkg/compiler/lib/src/parser/diet_parser_task.dart b/pkg/compiler/lib/src/parser/diet_parser_task.dart
index e975a83..aa635b9 100644
--- a/pkg/compiler/lib/src/parser/diet_parser_task.dart
+++ b/pkg/compiler/lib/src/parser/diet_parser_task.dart
@@ -19,8 +19,8 @@
   final Backend _backend;
   final DiagnosticReporter _reporter;
 
-  DietParserTask(this._idGenerator, this._backend, this._reporter,
-      Measurer measurer)
+  DietParserTask(
+      this._idGenerator, this._backend, this._reporter, Measurer measurer)
       : super(measurer);
 
   final String name = 'Diet Parser';
diff --git a/pkg/compiler/lib/src/parser/node_listener.dart b/pkg/compiler/lib/src/parser/node_listener.dart
index f3e343c..26cbab3 100644
--- a/pkg/compiler/lib/src/parser/node_listener.dart
+++ b/pkg/compiler/lib/src/parser/node_listener.dart
@@ -29,10 +29,12 @@
 
   void endLibraryName(Token libraryKeyword, Token semicolon) {
     Expression name = popNode();
-    pushNode(new LibraryName(libraryKeyword, name,
-          // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
-          // (element) instead of Metatada (node).
-          null));
+    pushNode(new LibraryName(
+        libraryKeyword,
+        name,
+        // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
+        // (element) instead of Metatada (node).
+        null));
   }
 
   void endImport(Token importKeyword, Token deferredKeyword, Token asKeyword,
@@ -41,37 +43,50 @@
     Identifier prefix = asKeyword != null ? popNode() : null;
     NodeList conditionalUris = popNode();
     StringNode uri = popLiteralString();
-    pushNode(new Import(importKeyword, uri, conditionalUris, prefix,
-          combinators,
-          // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
-          // (element) instead of Metatada (node).
-          null, isDeferred: deferredKeyword != null));
+    pushNode(new Import(
+        importKeyword,
+        uri,
+        conditionalUris,
+        prefix,
+        combinators,
+        // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
+        // (element) instead of Metatada (node).
+        null,
+        isDeferred: deferredKeyword != null));
   }
 
   void endExport(Token exportKeyword, Token semicolon) {
     NodeList combinators = popNode();
     NodeList conditionalUris = popNode();
     StringNode uri = popLiteralString();
-    pushNode(new Export(exportKeyword, uri, conditionalUris, combinators,
-          // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
-          // (element) instead of Metatada (node).
-          null));
+    pushNode(new Export(
+        exportKeyword,
+        uri,
+        conditionalUris,
+        combinators,
+        // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
+        // (element) instead of Metatada (node).
+        null));
   }
 
   void endPart(Token partKeyword, Token semicolon) {
     StringNode uri = popLiteralString();
-    pushNode(new Part(partKeyword, uri,
-          // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
-          // (element) instead of Metatada (node).
-          null));
+    pushNode(new Part(
+        partKeyword,
+        uri,
+        // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
+        // (element) instead of Metatada (node).
+        null));
   }
 
   void endPartOf(Token partKeyword, Token semicolon) {
     Expression name = popNode(); // name
-    pushNode(new PartOf(partKeyword, name,
-          // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
-          // (element) instead of Metatada (node).
-          null));
+    pushNode(new PartOf(
+        partKeyword,
+        name,
+        // TODO(sigmund): Import AST nodes have pointers to MetadataAnnotation
+        // (element) instead of Metatada (node).
+        null));
   }
 
   void endClassDeclaration(int interfacesCount, Token beginToken,
@@ -365,10 +380,10 @@
 
   void endSend(Token token) {
     NodeList arguments = popNode();
-    popNode(); // typeArguments
+    NodeList typeArguments = popNode();
     Node selector = popNode();
     // TODO(ahe): Handle receiver.
-    pushNode(new Send(null, selector, arguments));
+    pushNode(new Send(null, selector, arguments, typeArguments));
   }
 
   void endFunctionBody(int count, Token beginToken, Token endToken) {
diff --git a/pkg/compiler/lib/src/parser/parser.dart b/pkg/compiler/lib/src/parser/parser.dart
index e39ce38..7ed4327 100644
--- a/pkg/compiler/lib/src/parser/parser.dart
+++ b/pkg/compiler/lib/src/parser/parser.dart
@@ -1357,7 +1357,7 @@
     if (isFactoryDeclaration(token)) {
       token = parseFactoryMethod(token);
       listener.endMember();
-      assert (token != null);
+      assert(token != null);
       return token;
     }
 
diff --git a/pkg/compiler/lib/src/parser/parser_task.dart b/pkg/compiler/lib/src/parser/parser_task.dart
index e6e8bfe..54219d4 100644
--- a/pkg/compiler/lib/src/parser/parser_task.dart
+++ b/pkg/compiler/lib/src/parser/parser_task.dart
@@ -18,7 +18,9 @@
 class ParserTask extends CompilerTask {
   final Compiler compiler;
 
-  ParserTask(Compiler compiler): compiler = compiler, super(compiler.measurer);
+  ParserTask(Compiler compiler)
+      : compiler = compiler,
+        super(compiler.measurer);
 
   String get name => 'Parser';
 
diff --git a/pkg/compiler/lib/src/parser/partial_parser.dart b/pkg/compiler/lib/src/parser/partial_parser.dart
index c5d9d62..6aaa52c 100644
--- a/pkg/compiler/lib/src/parser/partial_parser.dart
+++ b/pkg/compiler/lib/src/parser/partial_parser.dart
@@ -12,7 +12,7 @@
 import 'parser.dart' show Parser;
 
 class PartialParser extends Parser {
-  PartialParser(Listener listener): super(listener);
+  PartialParser(Listener listener) : super(listener);
 
   Token parseClassBody(Token token) => skipClassBody(token);
 
diff --git a/pkg/compiler/lib/src/patch_parser.dart b/pkg/compiler/lib/src/patch_parser.dart
index da76073..3050c0d 100644
--- a/pkg/compiler/lib/src/patch_parser.dart
+++ b/pkg/compiler/lib/src/patch_parser.dart
@@ -149,7 +149,8 @@
   DiagnosticReporter get reporter => compiler.reporter;
 
   PatchParserTask(Compiler compiler)
-      : compiler = compiler, super(compiler.measurer);
+      : compiler = compiler,
+        super(compiler.measurer);
 
   /**
    * Scans a library patch file, applies the method patches and
@@ -248,7 +249,7 @@
  * declarations.
  */
 class PatchClassElementParser extends PartialParser {
-  PatchClassElementParser(Listener listener): super(listener);
+  PatchClassElementParser(Listener listener) : super(listener);
 
   Token parseClassBody(Token token) => fullParseClassBody(token);
 }
diff --git a/pkg/compiler/lib/src/resolution/class_hierarchy.dart b/pkg/compiler/lib/src/resolution/class_hierarchy.dart
index ef03ab5..551a47e 100644
--- a/pkg/compiler/lib/src/resolution/class_hierarchy.dart
+++ b/pkg/compiler/lib/src/resolution/class_hierarchy.dart
@@ -482,12 +482,12 @@
       if (interfaceType != null) {
         if (interfaceType.isMalformed) {
           reporter.reportErrorMessage(
-              superclass,
+              link.head,
               MessageKind.CANNOT_IMPLEMENT_MALFORMED,
               {'className': element.name, 'malformedType': interfaceType});
         } else if (interfaceType.isEnumType) {
           reporter.reportErrorMessage(
-              superclass,
+              link.head,
               MessageKind.CANNOT_IMPLEMENT_ENUM,
               {'className': element.name, 'enumType': interfaceType});
         } else if (!interfaceType.isInterfaceType) {
diff --git a/pkg/compiler/lib/src/resolution/constructors.dart b/pkg/compiler/lib/src/resolution/constructors.dart
index ae51c80..6a4ab3b 100644
--- a/pkg/compiler/lib/src/resolution/constructors.dart
+++ b/pkg/compiler/lib/src/resolution/constructors.dart
@@ -345,7 +345,7 @@
         if (!field.isMalformed) {
           registry.registerStaticUse(new StaticUse.fieldInit(field));
         }
-        checkForDuplicateInitializers(field, element.initializer);
+        checkForDuplicateInitializers(field, parameterNode);
         visitor.defineLocalVariable(parameterNode, initializingFormal);
         visitor.addToScope(initializingFormal);
         if (isConst) {
diff --git a/pkg/compiler/lib/src/resolution/members.dart b/pkg/compiler/lib/src/resolution/members.dart
index f566e40..abbf93f 100644
--- a/pkg/compiler/lib/src/resolution/members.dart
+++ b/pkg/compiler/lib/src/resolution/members.dart
@@ -3006,6 +3006,8 @@
   }
 
   ResolutionResult visitSend(Send node) {
+    // Resolve type arguments to ensure that these are well-formed types.
+    visit(node.typeArgumentsNode);
     if (node.isOperator) {
       // `a && b`, `a + b`, `-a`, or `a is T`.
       return handleOperatorSend(node);
diff --git a/pkg/compiler/lib/src/resolution/signatures.dart b/pkg/compiler/lib/src/resolution/signatures.dart
index 31673c2..faa927c 100644
--- a/pkg/compiler/lib/src/resolution/signatures.dart
+++ b/pkg/compiler/lib/src/resolution/signatures.dart
@@ -307,6 +307,11 @@
     DiagnosticReporter reporter = resolution.reporter;
 
     List<DartType> createTypeVariables(NodeList typeVariableNodes) {
+      if (element.isPatch) {
+        FunctionTypedElement origin = element.origin;
+        origin.computeType(resolution);
+        return origin.typeVariables;
+      }
       if (typeVariableNodes == null) return const <DartType>[];
 
       // Create the types and elements corresponding to [typeVariableNodes].
diff --git a/pkg/compiler/lib/src/resolved_uri_translator.dart b/pkg/compiler/lib/src/resolved_uri_translator.dart
index 41a96b3..84cdf50 100644
--- a/pkg/compiler/lib/src/resolved_uri_translator.dart
+++ b/pkg/compiler/lib/src/resolved_uri_translator.dart
@@ -35,8 +35,7 @@
   /// responsible for reporting errors.
   ///
   /// See [LibraryLoader] for terminology on URIs.
-  Uri translate(LibraryElement importingLibrary, Uri uri,
-      [Spannable spannable]);
+  Uri translate(LibraryElement importingLibrary, Uri uri, Spannable spannable);
 }
 
 /// A translator that forwards all methods to an internal
@@ -59,7 +58,7 @@
 
   @override
   Uri translate(LibraryElement importingLibrary, Uri resolvedUri,
-          [Spannable spannable]) =>
+          Spannable spannable) =>
       resolvedUriTranslator.translate(importingLibrary, resolvedUri, spannable);
 
   @override
@@ -86,8 +85,7 @@
   Map<String, Uri> get sdkLibraries => _sdkLibraries;
 
   @override
-  Uri translate(LibraryElement importingLibrary, Uri uri,
-      [Spannable spannable]) {
+  Uri translate(LibraryElement importingLibrary, Uri uri, Spannable spannable) {
     if (uri.scheme == 'dart') {
       return translateDartUri(importingLibrary, uri, spannable);
     }
diff --git a/pkg/compiler/lib/src/ssa/builder_kernel.dart b/pkg/compiler/lib/src/ssa/builder_kernel.dart
index c05772e..44c1c55 100644
--- a/pkg/compiler/lib/src/ssa/builder_kernel.dart
+++ b/pkg/compiler/lib/src/ssa/builder_kernel.dart
@@ -4,6 +4,7 @@
 
 import 'package:kernel/ast.dart' as ir;
 
+import '../closure.dart';
 import '../common.dart';
 import '../common/codegen.dart' show CodegenRegistry, CodegenWorkItem;
 import '../common/names.dart';
@@ -67,6 +68,12 @@
   final ResolvedAst resolvedAst;
   final CodegenRegistry registry;
 
+  /// Helper accessor for all kernel function-like targets (Procedure,
+  /// FunctionExpression, FunctionDeclaration) of the inner FunctionNode itself.
+  /// If the current target is not a function-like target, _targetFunction will
+  /// be null.
+  ir.FunctionNode _targetFunction;
+
   /// A stack of [DartType]s that have been seen during inlining of factory
   /// constructors.  These types are preserved in [HInvokeStatic]s and
   /// [HCreate]s inside the inline code and registered during code generation
@@ -81,6 +88,7 @@
   @override
   TreeElements get elements => resolvedAst.elements;
 
+
   SourceInformationBuilder sourceInformationBuilder;
   KernelAstAdapter astAdapter;
   LoopHandler<ir.Node> loopHandler;
@@ -114,6 +122,14 @@
     }
     if (originTarget is FunctionElement) {
       target = kernel.functions[originTarget];
+      // Closures require a lookup one level deeper in the closure class mapper.
+      if (target == null) {
+        ClosureClassMap classMap = compiler.closureToClassMapper
+            .getClosureToClassMapping(originTarget.resolvedAst);
+        if (classMap.closureElement != null) {
+          target = kernel.localFunctions[classMap.closureElement];
+        }
+      }
     } else if (originTarget is FieldElement) {
       target = kernel.fields[originTarget];
     }
@@ -123,11 +139,20 @@
     // TODO(het): no reason to do this here...
     HInstruction.idCounter = 0;
     if (target is ir.Procedure) {
-      buildProcedure(target);
+      _targetFunction = (target as ir.Procedure).function;
+      buildFunctionNode(_targetFunction);
     } else if (target is ir.Field) {
       buildField(target);
     } else if (target is ir.Constructor) {
       buildConstructor(target);
+    } else if (target is ir.FunctionExpression) {
+      _targetFunction = (target as ir.FunctionExpression).function;
+      buildFunctionNode(_targetFunction);
+    } else if (target is ir.FunctionDeclaration) {
+      _targetFunction = (target as ir.FunctionDeclaration).function;
+      buildFunctionNode(_targetFunction);
+    } else {
+      throw 'No case implemented to handle $target';
     }
     assert(graph.isValid());
     return graph;
@@ -334,10 +359,11 @@
         type, kind, original.instructionType, reifiedType, original);
   }
 
-  /// Builds a SSA graph for [procedure].
-  void buildProcedure(ir.Procedure procedure) {
+  /// Builds a SSA graph for FunctionNodes, found in FunctionExpressions and
+  /// Procedures.
+  void buildFunctionNode(ir.FunctionNode functionNode) {
     openFunction();
-    procedure.function.body.accept(this);
+    functionNode.body.accept(this);
     closeFunction();
   }
 
@@ -380,8 +406,17 @@
 
   @override
   void defaultExpression(ir.Expression expression) {
-    // TODO(het): This is only to get tests working
-    stack.add(graph.addConstantNull(compiler));
+    // TODO(het): This is only to get tests working.
+    String message = 'Unhandled ir.${expression.runtimeType}  $expression';
+    HInstruction nullValue = graph.addConstantNull(compiler);
+    HInstruction errorMessage =
+        graph.addConstantString(new DartString.literal(message), compiler);
+    HInstruction trap = new HForeignCode(js.js.parseForeignJS("#.#"),
+        backend.dynamicType, <HInstruction>[nullValue, errorMessage]);
+    trap.sideEffects
+      ..setAllSideEffects()
+      ..setDependsOnSomething();
+    push(trap);
   }
 
   /// Returns the current source element.
@@ -424,10 +459,10 @@
     if (returnStatement.expression == null) {
       value = graph.addConstantNull(compiler);
     } else {
-      assert(target is ir.Procedure);
+      assert(_targetFunction != null && _targetFunction is ir.FunctionNode);
       returnStatement.expression.accept(this);
       value = typeBuilder.potentiallyCheckOrTrustType(pop(),
-          astAdapter.getFunctionReturnType((target as ir.Procedure).function));
+          astAdapter.getFunctionReturnType(_targetFunction));
     }
     // TODO(het): Add source information
     // TODO(het): Set a return value instead of closing the function when we
@@ -787,7 +822,7 @@
   HInstruction setListRuntimeTypeInfoIfNeeded(
       HInstruction object, ir.ListLiteral listLiteral) {
     InterfaceType type = localsHandler
-        .substInContext(elements.getType(astAdapter.getNode(listLiteral)));
+        .substInContext(astAdapter.getDartTypeOfListLiteral(listLiteral));
     if (!backend.classNeedsRti(type.element) || type.treatAsRaw) {
       return object;
     }
@@ -818,7 +853,7 @@
           setListRuntimeTypeInfoIfNeeded(listInstruction, listLiteral);
     }
 
-    TypeMask type = astAdapter.typeOfNewList(targetElement, listLiteral);
+    TypeMask type = astAdapter.typeOfListLiteral(targetElement, listLiteral);
     if (!type.containsAll(compiler.closedWorld)) {
       listInstruction.instructionType = type;
     }
@@ -857,7 +892,7 @@
     assert(constructor.kind == ir.ProcedureKind.Factory);
 
     InterfaceType type = localsHandler
-        .substInContext(elements.getType(astAdapter.getNode(mapLiteral)));
+        .substInContext(astAdapter.getDartTypeOfMapLiteral(mapLiteral));
 
     ir.Class cls = constructor.enclosingClass;
 
@@ -941,11 +976,20 @@
       stack.add(graph.addConstant(
           astAdapter.getConstantFor(staticTarget.initializer), compiler));
     } else {
-      push(new HStatic(astAdapter.getMember(staticTarget),
-          astAdapter.inferredTypeOf(staticTarget)));
+      if (_isLazyStatic(staticTarget)) {
+        push(new HLazyStatic(astAdapter.getField(staticTarget),
+            astAdapter.inferredTypeOf(staticTarget)));
+      } else {
+        push(new HStatic(astAdapter.getMember(staticTarget),
+            astAdapter.inferredTypeOf(staticTarget)));
+      }
     }
   }
 
+  bool _isLazyStatic(ir.Member target) {
+    return astAdapter.isLazyStatic(target);
+  }
+
   @override
   void visitStaticSet(ir.StaticSet staticSet) {
     staticSet.value.accept(this);
@@ -1053,21 +1097,89 @@
     let.body.accept(this);
   }
 
-  // TODO(het): Also extract type arguments
-  /// Extracts the list of instructions for the expressions in the arguments.
-  List<HInstruction> _visitArguments(ir.Arguments arguments) {
+  /// Extracts the list of instructions for the positional subset of arguments.
+  List<HInstruction> _visitPositionalArguments(ir.Arguments arguments) {
     List<HInstruction> result = <HInstruction>[];
-
     for (ir.Expression argument in arguments.positional) {
       argument.accept(this);
       result.add(pop());
     }
+    return result;
+  }
+
+  /// Builds the list of instructions for the expressions in the arguments to a
+  /// dynamic target (member function).  Dynamic targets use stubs to add
+  /// defaulted arguments, so (unlike static targets) we do not add the default
+  /// values.
+  List<HInstruction> _visitArgumentsForDynamicTarget(
+      Selector selector, ir.Arguments arguments) {
+    List<HInstruction> values = _visitPositionalArguments(arguments);
+
+    if (arguments.named.isEmpty) return values;
+
+    var namedValues = <String, HInstruction>{};
     for (ir.NamedExpression argument in arguments.named) {
       argument.value.accept(this);
-      result.add(pop());
+      namedValues[argument.name] = pop();
+    }
+    for (String name in selector.callStructure.getOrderedNamedArguments()) {
+      values.add(namedValues[name]);
     }
 
-    return result;
+    return values;
+  }
+
+  /// Build argument list in canonical order for a static [target], including
+  /// filling in the defaulted argument value.
+  List<HInstruction> _visitArgumentsForStaticTarget(
+      ir.FunctionNode target, ir.Arguments arguments) {
+    // Visit arguments in source order, then re-order and fill in defaults.
+    var values = _visitPositionalArguments(arguments);
+
+    while (values.length < target.positionalParameters.length) {
+      ir.VariableDeclaration parameter =
+          target.positionalParameters[values.length];
+      values.add(_defaultValueForParameter(parameter));
+    }
+
+    if (arguments.named.isEmpty) return values;
+
+    var namedValues = <String, HInstruction>{};
+    for (ir.NamedExpression argument in arguments.named) {
+      argument.value.accept(this);
+      namedValues[argument.name] = pop();
+    }
+
+    // Visit named arguments in parameter-position order, selecting provided or
+    // default value.
+    // TODO(sra): Ensure the stored order is canonical so we don't have to
+    // sort. The old builder uses CallStructure.makeArgumentList which depends
+    // on the old element model.
+    var namedParameters = target.namedParameters.toList()
+      ..sort((ir.VariableDeclaration a, ir.VariableDeclaration b) =>
+          a.name.compareTo(b.name));
+    for (ir.VariableDeclaration parameter in namedParameters) {
+      HInstruction value = namedValues[parameter.name];
+      if (value == null) {
+        values.add(_defaultValueForParameter(parameter));
+      } else {
+        values.add(value);
+        namedValues.remove(parameter.name);
+      }
+    }
+    assert(namedValues.isEmpty);
+
+    return values;
+  }
+
+  HInstruction _defaultValueForParameter(ir.VariableDeclaration parameter) {
+    ir.Expression initializer = parameter.initializer;
+    if (initializer == null) return graph.addConstantNull(compiler);
+    // TODO(sra): Evaluate constant in ir.Node domain.
+    ConstantValue constant =
+        astAdapter.getConstantForParameterDefaultValue(initializer);
+    if (constant == null) return graph.addConstantNull(compiler);
+    return graph.addConstant(constant, compiler);
   }
 
   @override
@@ -1079,7 +1191,10 @@
     }
     TypeMask typeMask = astAdapter.returnTypeOf(target);
 
-    List<HInstruction> arguments = _visitArguments(invocation.arguments);
+    // TODO(sra): For JS interop external functions, use a different function to
+    // build arguments.
+    List<HInstruction> arguments =
+        _visitArgumentsForStaticTarget(target.function, invocation.arguments);
 
     _pushStaticInvocation(target, arguments, typeMask);
   }
@@ -1194,14 +1309,6 @@
     return stringConstant.primitiveValue.slowToString();
   }
 
-  // TODO(sra): Remove when handleInvokeStaticForeign fully implemented.
-  void unhandledForeign(ir.StaticInvocation invocation) {
-    ir.Procedure target = invocation.target;
-    TypeMask typeMask = astAdapter.returnTypeOf(target);
-    List<HInstruction> arguments = _visitArguments(invocation.arguments);
-    _pushStaticInvocation(target, arguments, typeMask);
-  }
-
   void handleForeignJsCurrentIsolateContext(ir.StaticInvocation invocation) {
     if (_unexpectedForeignArguments(invocation, 0, 0)) {
       stack.add(graph.addConstantNull(compiler)); // Result expected on stack.
@@ -1229,7 +1336,27 @@
   }
 
   void handleForeignJsCallInIsolate(ir.StaticInvocation invocation) {
-    unhandledForeign(invocation);
+    if (_unexpectedForeignArguments(invocation, 2, 2)) {
+      stack.add(graph.addConstantNull(compiler)); // Result expected on stack.
+      return;
+    }
+
+    List<HInstruction> inputs = _visitPositionalArguments(invocation.arguments);
+
+    if (!compiler.hasIsolateSupport) {
+      // If the isolate library is not used, we ignore the isolate argument and
+      // just invoke the closure.
+      push(new HInvokeClosure(new Selector.callClosure(0),
+          <HInstruction>[inputs[1]], backend.dynamicType));
+    } else {
+      // Call a helper method from the isolate library.
+      ir.Procedure callInIsolate = astAdapter.callInIsolate;
+      if (callInIsolate == null) {
+        compiler.reporter.internalError(astAdapter.getNode(invocation),
+            'Isolate library and compiler mismatch.');
+      }
+      _pushStaticInvocation(callInIsolate, inputs, backend.dynamicType);
+    }
   }
 
   void handleForeignDartClosureToJs(
@@ -1279,16 +1406,18 @@
   }
 
   void handleForeignJsSetStaticState(ir.StaticInvocation invocation) {
-    if (_unexpectedForeignArguments(invocation, 0, 0)) {
+    if (_unexpectedForeignArguments(invocation, 1, 1)) {
       stack.add(graph.addConstantNull(compiler)); // Result expected on stack.
       return;
     }
-    _visitArguments(invocation.arguments);
+
+    List<HInstruction> inputs = _visitPositionalArguments(invocation.arguments);
+
     String isolateName = backend.namer.staticStateHolder;
     SideEffects sideEffects = new SideEffects.empty();
     sideEffects.setAllSideEffects();
-    push(new HForeignCode(js.js.parseForeignJS("$isolateName = #"),
-        backend.dynamicType, <HInstruction>[pop()],
+    push(new HForeignCode(
+        js.js.parseForeignJS("$isolateName = #"), backend.dynamicType, inputs,
         nativeBehavior: native.NativeBehavior.CHANGES_OTHER,
         effects: sideEffects));
   }
@@ -1486,7 +1615,7 @@
       stack.add(graph.addConstantNull(compiler)); // Result expected on stack.
       return;
     }
-    List<HInstruction> inputs = _visitArguments(invocation.arguments);
+    List<HInstruction> inputs = _visitPositionalArguments(invocation.arguments);
     push(new HStringConcat(inputs[0], inputs[1], backend.stringType));
   }
 
@@ -1530,6 +1659,51 @@
     }
   }
 
+  @override
+  visitFunctionNode(ir.FunctionNode node) {
+    LocalFunctionElement methodElement = astAdapter.getElement(node);
+    ClosureClassMap nestedClosureData = compiler.closureToClassMapper
+        .getClosureToClassMapping(methodElement.resolvedAst);
+    assert(nestedClosureData != null);
+    assert(nestedClosureData.closureClassElement != null);
+    ClosureClassElement closureClassElement =
+        nestedClosureData.closureClassElement;
+    FunctionElement callElement = nestedClosureData.callElement;
+    // TODO(ahe): This should be registered in codegen, not here.
+    // TODO(johnniwinther): Is [registerStaticUse] equivalent to
+    // [addToWorkList]?
+    registry?.registerStaticUse(new StaticUse.foreignUse(callElement));
+
+    List<HInstruction> capturedVariables = <HInstruction>[];
+    closureClassElement.closureFields.forEach((ClosureFieldElement field) {
+      Local capturedLocal =
+          nestedClosureData.getLocalVariableForClosureField(field);
+      assert(capturedLocal != null);
+      capturedVariables.add(localsHandler.readLocal(capturedLocal));
+    });
+
+    TypeMask type =
+        new TypeMask.nonNullExact(closureClassElement, compiler.closedWorld);
+    // TODO(efortuna): Add source information here.
+    push(new HCreate(closureClassElement, capturedVariables, type));
+
+    registry?.registerInstantiatedClosure(methodElement);
+  }
+
+  @override
+  visitFunctionDeclaration(ir.FunctionDeclaration declaration) {
+    assert(isReachable);
+    declaration.function.accept(this);
+    LocalFunctionElement localFunction = astAdapter.getElement(
+        declaration.function);
+    localsHandler.updateLocal(localFunction, pop());
+  }
+
+  @override
+  void visitFunctionExpression(ir.FunctionExpression funcExpression) {
+    funcExpression.function.accept(this);
+  }
+
   // TODO(het): Decide when to inline
   @override
   void visitMethodInvocation(ir.MethodInvocation invocation) {
@@ -1538,12 +1712,13 @@
     if (_handleEqualsNull(invocation)) return;
     invocation.receiver.accept(this);
     HInstruction receiver = pop();
-
+    Selector selector = astAdapter.getSelector(invocation);
     _pushDynamicInvocation(
         invocation,
         astAdapter.typeOfInvocation(invocation),
         <HInstruction>[receiver]
-          ..addAll(_visitArguments(invocation.arguments)));
+          ..addAll(
+              _visitArgumentsForDynamicTarget(selector, invocation.arguments)));
   }
 
   bool _handleEqualsNull(ir.MethodInvocation invocation) {
@@ -1584,9 +1759,10 @@
 
   @override
   void visitSuperMethodInvocation(ir.SuperMethodInvocation invocation) {
-    List<HInstruction> arguments = _visitArguments(invocation.arguments);
-    HInstruction receiver = localsHandler.readThis();
     Selector selector = astAdapter.getSelector(invocation);
+    List<HInstruction> arguments = _visitArgumentsForStaticTarget(
+        invocation.interfaceTarget.function, invocation.arguments);
+    HInstruction receiver = localsHandler.readThis();
     ir.Class surroundingClass = _containingClass(invocation);
 
     List<HInstruction> inputs = <HInstruction>[];
@@ -1612,7 +1788,9 @@
   @override
   void visitConstructorInvocation(ir.ConstructorInvocation invocation) {
     ir.Constructor target = invocation.target;
-    List<HInstruction> arguments = _visitArguments(invocation.arguments);
+    // TODO(sra): For JS-interop targets, process arguments differently.
+    List<HInstruction> arguments =
+        _visitArgumentsForStaticTarget(target.function, invocation.arguments);
     TypeMask typeMask = new TypeMask.nonNullExact(
         astAdapter.getElement(target.enclosingClass), compiler.closedWorld);
     _pushStaticInvocation(target, arguments, typeMask);
@@ -1623,8 +1801,44 @@
     isExpression.operand.accept(this);
     HInstruction expression = pop();
 
+    // TODO(sra): Convert the type testing logic here to use ir.DartType.
     DartType type = astAdapter.getDartType(isExpression.type);
 
+    type = localsHandler.substInContext(type).unaliased;
+
+    if (type is MethodTypeVariableType) {
+      push(graph.addConstantBool(true, compiler));
+      return;
+    }
+
+    if (type is MalformedType) {
+      ErroneousElement element = type.element;
+      generateTypeError(isExpression, element.message);
+      push(new HIs.compound(type, expression, pop(), backend.boolType));
+      return;
+    }
+
+    if (type.isFunctionType) {
+      List arguments = <HInstruction>[buildFunctionType(type), expression];
+      _pushDynamicInvocation(isExpression, backend.boolType, arguments,
+          selector: new Selector.call(
+              new PrivateName('_isTest', astAdapter.jsHelperLibrary),
+              CallStructure.ONE_ARG));
+      push(new HIs.compound(type, expression, pop(), backend.boolType));
+      return;
+    }
+
+    if (type.isTypeVariable) {
+      HInstruction runtimeType =
+          typeBuilder.addTypeVariableReference(type, sourceElement);
+      _pushStaticInvocation(astAdapter.checkSubtypeOfRuntimeType,
+          <HInstruction>[expression, runtimeType], backend.boolType);
+      push(new HIs.variable(type, expression, pop(), backend.boolType));
+      return;
+    }
+
+    // TODO(sra): Type with type parameters.
+
     if (backend.hasDirectCheckFor(type)) {
       push(new HIs.direct(type, expression, backend.boolType));
       return;
diff --git a/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart b/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
index 07c515c..1343be0 100644
--- a/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
+++ b/pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart
@@ -72,6 +72,9 @@
       _compiler.globalInference.results.resultOf(e);
 
   ConstantValue getConstantForSymbol(ir.SymbolLiteral node) {
+    if (kernel.syntheticNodes.contains(node)) {
+      return _backend.constantSystem.createSymbol(_compiler, node.value);
+    }
     ast.Node astNode = getNode(node);
     ConstantValue constantValue = _backend.constants
         .getConstantValueForNode(astNode, _resolvedAst.elements);
@@ -92,6 +95,8 @@
 
   MethodElement getMethod(ir.Node node) => getElement(node).declaration;
 
+  FieldElement getField(ir.Node node) => getElement(node).declaration;
+
   ClassElement getClass(ir.Node node) => getElement(node).declaration;
 
   ast.Node getNode(ir.Node node) {
@@ -101,6 +106,16 @@
     return result;
   }
 
+  ast.Node getNodeOrNull(ir.Node node) {
+    return _nodeToAst[node];
+  }
+
+  void assertNodeIsSynthetic(ir.Node node) {
+    assert(invariant(
+        CURRENT_ELEMENT_SPANNABLE, kernel.syntheticNodes.contains(node),
+        message: "No synthetic marker found for $node"));
+  }
+
   Local getLocal(ir.VariableDeclaration variable) {
     // If this is a synthetic local, return the synthetic local
     if (variable.name == null) {
@@ -204,7 +219,12 @@
     return _resultOf(_target).typeOfSend(getNode(send));
   }
 
-  TypeMask typeOfNewList(Element owner, ir.ListLiteral listLiteral) {
+  TypeMask typeOfListLiteral(Element owner, ir.ListLiteral listLiteral) {
+    ast.Node node = getNodeOrNull(listLiteral);
+    if (node == null) {
+      assertNodeIsSynthetic(listLiteral);
+      return _compiler.closedWorld.commonMasks.growableListType;
+    }
     return _resultOf(owner).typeOfNewList(getNode(listLiteral)) ??
         _compiler.closedWorld.commonMasks.dynamicType;
   }
@@ -272,6 +292,19 @@
     return constantValue;
   }
 
+  ConstantValue getConstantForParameterDefaultValue(ir.Node defaultExpression) {
+    // TODO(27394): Evaluate constant expressions in ir.Node domain.
+    // In the interim, expand the Constantifier and do this:
+    //
+    //     ConstantExpression constantExpression =
+    //         defaultExpression.accept(new Constantifier(this));
+    //     assert(constantExpression != null);
+    ConstantExpression constantExpression =
+        kernel.parameterInitializerNodeToConstant[defaultExpression];
+    if (constantExpression == null) return null;
+    return _backend.constants.getConstantValue(constantExpression);
+  }
+
   ConstantValue getConstantForType(ir.DartType irType) {
     DartType type = getDartType(irType);
     return _backend.constantSystem.createType(_compiler, type.asRaw());
@@ -286,6 +319,15 @@
     return _backend.isInterceptedSelector(selector);
   }
 
+  // Is the member a lazy initialized static or top-level member?
+  bool isLazyStatic(ir.Member member) {
+    if (member is ir.Field) {
+      FieldElement field = _nodeToElement[member];
+      return field.constant == null;
+    }
+    return false;
+  }
+
   LibraryElement get jsHelperLibrary => _backend.helpers.jsHelperLibrary;
 
   JumpTarget getTargetDefinition(ir.Node node) =>
@@ -315,6 +357,12 @@
       TypeMaskFactory.inferredReturnTypeForElement(
           _backend.helpers.checkConcurrentModificationError, _compiler);
 
+  ir.Procedure get checkSubtype =>
+      kernel.functions[_backend.helpers.checkSubtype];
+
+  ir.Procedure get checkSubtypeOfRuntimeType =>
+      kernel.functions[_backend.helpers.checkSubtypeOfRuntimeType];
+
   ir.Procedure get assertHelper =>
       kernel.functions[_backend.helpers.assertHelper];
 
@@ -343,6 +391,9 @@
   ir.Procedure get currentIsolate =>
       kernel.functions[_backend.helpers.currentIsolate];
 
+  ir.Procedure get callInIsolate =>
+      kernel.functions[_backend.helpers.callInIsolate];
+
   bool isInForeignLibrary(ir.Member member) =>
       _backend.isForeign(getElement(member));
 
@@ -387,6 +438,21 @@
     return types.map(getDartType).toList();
   }
 
+  DartType getDartTypeOfListLiteral(ir.ListLiteral list) {
+    ast.Node node = getNodeOrNull(list);
+    if (node != null) return elements.getType(node);
+    assertNodeIsSynthetic(list);
+    return _compiler.coreTypes.listType(getDartType(list.typeArgument));
+  }
+
+  DartType getDartTypeOfMapLiteral(ir.MapLiteral literal) {
+    ast.Node node = getNodeOrNull(literal);
+    if (node != null) return elements.getType(node);
+    assertNodeIsSynthetic(literal);
+    return _compiler.coreTypes
+        .mapType(getDartType(literal.keyType), getDartType(literal.valueType));
+  }
+
   DartType getFunctionReturnType(ir.FunctionNode node) {
     return getDartType(node.returnType);
   }
diff --git a/pkg/compiler/lib/src/tree/nodes.dart b/pkg/compiler/lib/src/tree/nodes.dart
index ff36cfe..1e5f9dd 100644
--- a/pkg/compiler/lib/src/tree/nodes.dart
+++ b/pkg/compiler/lib/src/tree/nodes.dart
@@ -593,6 +593,7 @@
   final Node receiver;
   final Node selector;
   final NodeList argumentsNode;
+  final NodeList typeArgumentsNode;
 
   /// Whether this is a conditional send of the form `a?.b`.
   final bool isConditional;
@@ -603,16 +604,19 @@
       [this.receiver,
       this.selector,
       this.argumentsNode,
+      this.typeArgumentsNode,
       this.isConditional = false]);
   Send.postfix(this.receiver, this.selector,
       [Node argument = null, this.isConditional = false])
       : argumentsNode = (argument == null)
             ? new Postfix()
-            : new Postfix.singleton(argument);
+            : new Postfix.singleton(argument),
+        typeArgumentsNode = null;
   Send.prefix(this.receiver, this.selector,
       [Node argument = null, this.isConditional = false])
       : argumentsNode =
-            (argument == null) ? new Prefix() : new Prefix.singleton(argument);
+            (argument == null) ? new Prefix() : new Prefix.singleton(argument),
+        typeArgumentsNode = null;
 
   Send asSend() => this;
 
@@ -695,7 +699,8 @@
 
   Send copyWithReceiver(Node newReceiver, bool isConditional) {
     assert(receiver == null);
-    return new Send(newReceiver, selector, argumentsNode, isConditional);
+    return new Send(
+        newReceiver, selector, argumentsNode, typeArgumentsNode, isConditional);
   }
 }
 
@@ -713,7 +718,7 @@
   final Operator assignmentOperator;
   SendSet(receiver, selector, this.assignmentOperator, argumentsNode,
       [bool isConditional = false])
-      : super(receiver, selector, argumentsNode, isConditional);
+      : super(receiver, selector, argumentsNode, null, isConditional);
   SendSet.postfix(receiver, selector, this.assignmentOperator,
       [Node argument = null, bool isConditional = false])
       : super.postfix(receiver, selector, argument, isConditional);
diff --git a/pkg/compiler/lib/src/tree/unparser.dart b/pkg/compiler/lib/src/tree/unparser.dart
index 12d4141..5d1d154 100644
--- a/pkg/compiler/lib/src/tree/unparser.dart
+++ b/pkg/compiler/lib/src/tree/unparser.dart
@@ -457,6 +457,7 @@
       visit(argNode.receiver);
     } else {
       if (spacesNeeded) write(' ');
+      visit(node.typeArgumentsNode);
       visit(node.argumentsNode);
     }
   }
diff --git a/pkg/compiler/lib/src/typechecker.dart b/pkg/compiler/lib/src/typechecker.dart
index 74831e1..3149368 100644
--- a/pkg/compiler/lib/src/typechecker.dart
+++ b/pkg/compiler/lib/src/typechecker.dart
@@ -685,8 +685,7 @@
       assert(invariant(node, element != null,
           message: 'Missing element for identifier'));
       assert(invariant(
-          node,
-          element.isVariable || element.isParameter || element.isField,
+          node, element.isVariable || element.isParameter || element.isField,
           message: 'Unexpected context element ${element}'));
       return element.computeType(resolution);
     }
diff --git a/pkg/compiler/lib/src/universe/world_builder.dart b/pkg/compiler/lib/src/universe/world_builder.dart
index 49deb8e..bd07cc8 100644
--- a/pkg/compiler/lib/src/universe/world_builder.dart
+++ b/pkg/compiler/lib/src/universe/world_builder.dart
@@ -14,7 +14,9 @@
 import '../core_types.dart' show CoreClasses;
 import '../dart_types.dart';
 import '../elements/elements.dart';
+import '../elements/entities.dart';
 import '../universe/class_set.dart' show Instantiation;
+import '../util/enumset.dart';
 import '../util/util.dart';
 import '../world.dart' show World, ClosedWorld, OpenWorld, WorldImpl;
 import 'selector.dart' show Selector;
@@ -129,9 +131,6 @@
   /// instantiated classes.
   // TODO(johnniwinther): Improve semantic precision.
   Iterable<DartType> get instantiatedTypes;
-
-  /// Returns `true` if [member] is invoked as a setter.
-  bool hasInvokedSetter(Element member, World world);
 }
 
 abstract class ResolutionWorldBuilder implements WorldBuilder {
@@ -139,7 +138,7 @@
   /// variables.
   ///
   /// A live function is one whose enclosing member function has been enqueued.
-  Set<Element> get closuresWithFreeTypeVariables;
+  Iterable<Element> get closuresWithFreeTypeVariables;
 
   /// Set of (live) `call` methods whose signatures reference type variables.
   ///
@@ -167,6 +166,9 @@
   /// arguments are used in live factory constructors.
   void forEachInstantiatedClass(f(ClassElement cls, InstantiationInfo info));
 
+  /// Returns `true` if [member] is invoked as a setter.
+  bool hasInvokedSetter(Element member);
+
   /// `true` of `Object.runtimeType` is supported.
   bool get hasRuntimeTypeSupport;
 
@@ -370,6 +372,23 @@
   final Map<String, Map<Selector, SelectorConstraints>> _invokedSetters =
       <String, Map<Selector, SelectorConstraints>>{};
 
+  final Map<ClassElement, _ClassUsage> _processedClasses =
+      <ClassElement, _ClassUsage>{};
+
+  /// Map of registers usage of instance members of live classes.
+  final Map<MemberEntity, _MemberUsage> _instanceMemberUsage =
+      <MemberEntity, _MemberUsage>{};
+
+  /// Map containing instance members of live classes that are not yet live
+  /// themselves.
+  final Map<String, Set<_MemberUsage>> _instanceMembersByName =
+      <String, Set<_MemberUsage>>{};
+
+  /// Map containing instance methods of live classes that are not yet
+  /// closurized.
+  final Map<String, Set<_MemberUsage>> _instanceFunctionsByName =
+      <String, Set<_MemberUsage>>{};
+
   /// Fields set.
   final Set<Element> fieldSetters = new Set<Element>();
   final Set<DartType> isChecks = new Set<DartType>();
@@ -413,11 +432,20 @@
 
   OpenWorld _openWorld;
 
-  ResolutionWorldBuilderImpl(Backend backend, CoreClasses coreClasses,
-      CacheStrategy cacheStrategy, this.selectorConstraintsStrategy) {
-    _openWorld = new WorldImpl(this, backend, coreClasses, cacheStrategy);
+  final Backend _backend;
+  final Resolution _resolution;
+
+  ResolutionWorldBuilderImpl(Backend backend, Resolution resolution,
+      CacheStrategy cacheStrategy, this.selectorConstraintsStrategy)
+      : this._backend = backend,
+        this._resolution = resolution {
+    _openWorld =
+        new WorldImpl(this, backend, resolution.coreClasses, cacheStrategy);
   }
 
+  Iterable<ClassElement> get processedClasses => _processedClasses.keys
+      .where((cls) => _processedClasses[cls].isInstantiated);
+
   OpenWorld get openWorld => _openWorld;
 
   /// All directly instantiated classes, that is, classes with a generative
@@ -468,33 +496,32 @@
   // TODO(johnniwinther): Fully enforce the separation between exact, through
   // subclass and through subtype instantiated types/classes.
   // TODO(johnniwinther): Support unknown type arguments for generic types.
-  void registerTypeInstantiation(InterfaceType type,
+  void registerTypeInstantiation(InterfaceType type, ClassUsed classUsed,
       {ConstructorElement constructor,
       bool byMirrors: false,
-      bool isNative: false,
-      bool isRedirection: false,
-      void onImplemented(ClassElement cls)}) {
+      bool isRedirection: false}) {
     ClassElement cls = type.element;
+    cls.ensureResolved(_resolution);
     InstantiationInfo info =
         _instantiationInfo.putIfAbsent(cls, () => new InstantiationInfo());
     Instantiation kind = Instantiation.UNINSTANTIATED;
-    if (!cls.isAbstract
+    bool isNative = _backend.isNative(cls);
+    if (!cls.isAbstract ||
         // We can't use the closed-world assumption with native abstract
         // classes; a native abstract class may have non-abstract subclasses
         // not declared to the program.  Instances of these classes are
         // indistinguishable from the abstract class.
-        ||
-        isNative
+        isNative ||
         // Likewise, if this registration comes from the mirror system,
         // all bets are off.
         // TODO(herhut): Track classes required by mirrors seperately.
-        ||
         byMirrors) {
       if (isNative || byMirrors) {
         kind = Instantiation.ABSTRACTLY_INSTANTIATED;
       } else {
         kind = Instantiation.DIRECTLY_INSTANTIATED;
       }
+      _processInstantiatedClass(cls, classUsed);
     }
     info.addInstantiation(constructor, type, kind,
         isRedirection: isRedirection);
@@ -502,6 +529,11 @@
     // TODO(johnniwinther): Use [_instantiationInfo] to compute this information
     // instead.
     if (_implementedClasses.add(cls)) {
+      void onImplemented(ClassElement cls) {
+        _ClassUsage usage = _getClassUsage(cls);
+        classUsed(usage.cls, usage.implement());
+      }
+
       onImplemented(cls);
       cls.allSupertypes.forEach((InterfaceType supertype) {
         if (_implementedClasses.add(supertype.element)) {
@@ -516,13 +548,13 @@
     getInstantiationMap().forEach(f);
   }
 
-  bool _hasMatchingSelector(Map<Selector, SelectorConstraints> selectors,
-      Element member, OpenWorld world) {
+  bool _hasMatchingSelector(
+      Map<Selector, SelectorConstraints> selectors, Element member) {
     if (selectors == null) return false;
     for (Selector selector in selectors.keys) {
       if (selector.appliesUnnamed(member)) {
         SelectorConstraints masks = selectors[selector];
-        if (masks.applies(member, selector, world)) {
+        if (masks.applies(member, selector, _openWorld)) {
           return true;
         }
       }
@@ -574,27 +606,63 @@
     return instantiationMap;
   }
 
-  bool hasInvocation(Element member, OpenWorld world) {
-    return _hasMatchingSelector(_invokedNames[member.name], member, world);
+  bool _hasInvocation(Element member) {
+    return _hasMatchingSelector(_invokedNames[member.name], member);
   }
 
-  bool hasInvokedGetter(Element member, OpenWorld world) {
-    return _hasMatchingSelector(_invokedGetters[member.name], member, world) ||
+  bool _hasInvokedGetter(Element member) {
+    return _hasMatchingSelector(_invokedGetters[member.name], member) ||
         member.isFunction && methodsNeedingSuperGetter.contains(member);
   }
 
-  bool hasInvokedSetter(Element member, OpenWorld world) {
-    return _hasMatchingSelector(_invokedSetters[member.name], member, world);
+  bool hasInvokedSetter(Element member) {
+    return _hasMatchingSelector(_invokedSetters[member.name], member);
   }
 
-  bool registerDynamicUse(DynamicUse dynamicUse) {
+  void registerDynamicUse(DynamicUse dynamicUse, MemberUsed memberUsed) {
+    Selector selector = dynamicUse.selector;
+    String methodName = selector.name;
     switch (dynamicUse.kind) {
       case DynamicUseKind.INVOKE:
-        return _registerNewSelector(dynamicUse, _invokedNames);
+        if (_registerNewSelector(dynamicUse, _invokedNames)) {
+          _processInstanceMembers(methodName, (_MemberUsage usage) {
+            if (dynamicUse.appliesUnnamed(usage.entity, _openWorld)) {
+              memberUsed(usage.entity, usage.invoke());
+              return true;
+            }
+            return false;
+          });
+        }
+        break;
       case DynamicUseKind.GET:
-        return _registerNewSelector(dynamicUse, _invokedGetters);
+        if (_registerNewSelector(dynamicUse, _invokedGetters)) {
+          _processInstanceMembers(methodName, (_MemberUsage usage) {
+            if (dynamicUse.appliesUnnamed(usage.entity, _openWorld)) {
+              memberUsed(usage.entity, usage.read());
+              return true;
+            }
+            return false;
+          });
+          _processInstanceFunctions(methodName, (_MemberUsage usage) {
+            if (dynamicUse.appliesUnnamed(usage.entity, _openWorld)) {
+              memberUsed(usage.entity, usage.read());
+              return true;
+            }
+            return false;
+          });
+        }
+        break;
       case DynamicUseKind.SET:
-        return _registerNewSelector(dynamicUse, _invokedSetters);
+        if (_registerNewSelector(dynamicUse, _invokedSetters)) {
+          _processInstanceMembers(methodName, (_MemberUsage usage) {
+            if (dynamicUse.appliesUnnamed(usage.entity, _openWorld)) {
+              memberUsed(usage.entity, usage.write());
+              return true;
+            }
+            return false;
+          });
+        }
+        break;
     }
   }
 
@@ -659,6 +727,16 @@
     closurizedMembers.remove(element);
     fieldSetters.remove(element);
     _instantiationInfo.remove(element);
+
+    void removeUsage(Set<_MemberUsage> set, Element element) {
+      if (set == null) return;
+      set.removeAll(
+          set.where((_MemberUsage usage) => usage.entity == element).toList());
+    }
+
+    _processedClasses.remove(element);
+    removeUsage(_instanceMembersByName[element.name], element);
+    removeUsage(_instanceFunctionsByName[element.name], element);
   }
 
   // TODO(ahe): Replace this method with something that is O(1), for example,
@@ -670,6 +748,121 @@
       return closure.executableContext == element;
     }));
   }
+
+  /// Return the canonical [_ClassUsage] for [cls].
+  _ClassUsage _getClassUsage(ClassElement cls) {
+    return _processedClasses.putIfAbsent(cls, () {
+      cls.ensureResolved(_resolution);
+      _ClassUsage usage = new _ClassUsage(cls);
+      _resolution.ensureClassMembers(cls);
+      return usage;
+    });
+  }
+
+  /// Register [cls] and all its superclasses as instantiated.
+  void _processInstantiatedClass(ClassElement cls, ClassUsed classUsed) {
+    // Registers [superclass] as instantiated. Returns `true` if it wasn't
+    // already instantiated and we therefore have to process its superclass as
+    // well.
+    bool processClass(ClassElement superclass) {
+      _ClassUsage usage = _getClassUsage(superclass);
+      if (!usage.isInstantiated) {
+        classUsed(usage.cls, usage.instantiate());
+        return true;
+      }
+      return false;
+    }
+
+    while (cls != null && processClass(cls)) {
+      cls = cls.superclass;
+    }
+  }
+
+  /// Computes usage for all members declared by [cls]. Calls [membersUsed] with
+  /// the usage changes for each member.
+  void processClassMembers(ClassElement cls, MemberUsed memberUsed) {
+    cls.implementation.forEachMember((ClassElement cls, MemberElement member) {
+      _processInstantiatedClassMember(cls, member, memberUsed);
+    });
+  }
+
+  /// Call [updateUsage] on all [MemberUsage]s in the set in [map] for
+  /// [memberName]. If [updateUsage] returns `true` the usage is removed from
+  /// the set.
+  void _processSet(Map<String, Set<_MemberUsage>> map, String memberName,
+      bool updateUsage(_MemberUsage e)) {
+    Set<_MemberUsage> members = map[memberName];
+    if (members == null) return;
+    // [f] might add elements to [: map[memberName] :] during the loop below
+    // so we create a new list for [: map[memberName] :] and prepend the
+    // [remaining] members after the loop.
+    map[memberName] = new Set<_MemberUsage>();
+    Set<_MemberUsage> remaining = new Set<_MemberUsage>();
+    for (_MemberUsage usage in members) {
+      if (!updateUsage(usage)) remaining.add(usage);
+    }
+    map[memberName].addAll(remaining);
+  }
+
+  void _processInstanceMembers(String name, bool updateUsage(_MemberUsage e)) {
+    _processSet(_instanceMembersByName, name, updateUsage);
+  }
+
+  void _processInstanceFunctions(String name, bool updateUsage(_MemberUsage e)) {
+    _processSet(_instanceFunctionsByName, name, updateUsage);
+  }
+
+  void _processInstantiatedClassMember(
+      ClassElement cls, MemberElement member, MemberUsed memberUsed) {
+    assert(invariant(member, member.isDeclaration));
+    if (!member.isInstanceMember) return;
+    String memberName = member.name;
+    member.computeType(_resolution);
+    EnumSet<MemberUse> useSet = new EnumSet<MemberUse>();
+    // The obvious thing to test here would be "member.isNative",
+    // however, that only works after metadata has been parsed/analyzed,
+    // and that may not have happened yet.
+    // So instead we use the enclosing class, which we know have had
+    // its metadata parsed and analyzed.
+    // Note: this assumes that there are no non-native fields on native
+    // classes, which may not be the case when a native class is subclassed.
+    bool isNative = _backend.isNative(cls);
+    _MemberUsage usage = _instanceMemberUsage.putIfAbsent(member, () {
+      _MemberUsage usage = new _MemberUsage(member, isNative: isNative);
+      useSet.addAll(usage.appliedUse);
+      if (member.isField && isNative) {
+        _openWorld.registerUsedElement(member);
+      }
+
+      if (_hasInvokedGetter(member)) {
+        useSet.addAll(usage.read());
+      }
+      if (_hasInvocation(member)) {
+        useSet.addAll(usage.invoke());
+      }
+      if (hasInvokedSetter(member)) {
+        useSet.addAll(usage.write());
+      }
+
+      if (usage.pendingUse.contains(MemberUse.NORMAL)) {
+        // The element is not yet used. Add it to the list of instance
+        // members to still be processed.
+        _instanceMembersByName
+            .putIfAbsent(memberName, () => new Set<_MemberUsage>())
+            .add(usage);
+      }
+      if (usage.pendingUse.contains(MemberUse.CLOSURIZE)) {
+        // Store the member in [instanceFunctionsByName] to catch
+        // getters on the function.
+        _instanceFunctionsByName
+            .putIfAbsent(memberName, () => new Set<_MemberUsage>())
+            .add(usage);
+      }
+
+      memberUsed(usage.entity, useSet);
+      return usage;
+    });
+  }
 }
 
 /// World builder specific to codegen.
@@ -685,6 +878,9 @@
   void forEachInvokedSetter(
       f(String name, Map<Selector, SelectorConstraints> selectors));
 
+  /// Returns `true` if [member] is invoked as a setter.
+  bool hasInvokedSetter(Element member, ClosedWorld world);
+
   bool hasInvokedGetter(Element member, ClosedWorld world);
 
   Map<Selector, SelectorConstraints> invocationsByName(String name);
@@ -932,3 +1128,323 @@
     }
   }
 }
+
+abstract class _AbstractUsage<T> {
+  final EnumSet<T> _pendingUse = new EnumSet<T>();
+
+  _AbstractUsage() {
+    _pendingUse.addAll(_originalUse);
+  }
+
+  /// Returns the possible uses of [entity] that have not yet been registered.
+  EnumSet<T> get pendingUse => _pendingUse;
+
+  /// Returns the uses of [entity] that have been registered.
+  EnumSet<T> get appliedUse => _originalUse.minus(_pendingUse);
+
+  EnumSet<T> get _originalUse;
+}
+
+/// Registry for the observed use of a member [entity] in the open world.
+abstract class _MemberUsage extends _AbstractUsage<MemberUse> {
+  // TODO(johnniwinther): Change [Entity] to [MemberEntity].
+  final Entity entity;
+
+  _MemberUsage.internal(this.entity);
+
+  factory _MemberUsage(MemberEntity member, {bool isNative: false}) {
+    if (member.isField) {
+      if (member.isAssignable) {
+        return new _FieldUsage(member, isNative: isNative);
+      } else {
+        return new _FinalFieldUsage(member, isNative: isNative);
+      }
+    } else if (member.isGetter) {
+      return new _GetterUsage(member);
+    } else if (member.isSetter) {
+      return new _SetterUsage(member);
+    } else {
+      assert(member.isFunction);
+      return new _FunctionUsage(member);
+    }
+  }
+
+  /// `true` if [entity] has been read as a value. For a field this is a normal
+  /// read access, for a function this is a closurization.
+  bool get hasRead => false;
+
+  /// `true` if a value has been written to [entity].
+  bool get hasWrite => false;
+
+  /// `true` if an invocation has been performed on the value [entity]. For a
+  /// function this is a normal invocation, for a field this is a read access
+  /// followed by an invocation of the function-like value.
+  bool get hasInvoke => false;
+
+  /// `true` if [entity] has been used in all the ways possible.
+  bool get fullyUsed;
+
+  /// Registers a read of the value of [entity] and returns the new [MemberUse]s
+  /// that it caused.
+  ///
+  /// For a field this is a normal read access, for a function this is a
+  /// closurization.
+  EnumSet<MemberUse> read() => MemberUses.NONE;
+
+  /// Registers a write of a value to [entity] and returns the new [MemberUse]s
+  /// that it caused.
+  EnumSet<MemberUse> write() => MemberUses.NONE;
+
+  /// Registers an invocation on the value of [entity] and returns the new
+  /// [MemberUse]s that it caused.
+  ///
+  /// For a function this is a normal invocation, for a field this is a read
+  /// access followed by an invocation of the function-like value.
+  EnumSet<MemberUse> invoke() => MemberUses.NONE;
+
+  /// Registers all possible uses of [entity] and returns the new [MemberUse]s
+  /// that it caused.
+  EnumSet<MemberUse> fullyUse() => MemberUses.NONE;
+
+  @override
+  EnumSet<MemberUse> get _originalUse => MemberUses.NORMAL_ONLY;
+
+  int get hashCode => entity.hashCode;
+
+  bool operator ==(other) {
+    if (identical(this, other)) return true;
+    if (other is! _MemberUsage) return false;
+    return entity == other.entity;
+  }
+
+  String toString() => entity.toString();
+}
+
+class _FieldUsage extends _MemberUsage {
+  bool hasRead = false;
+  bool hasWrite = false;
+
+  _FieldUsage(FieldEntity field, {bool isNative: false})
+      : super.internal(field) {
+    if (!isNative) {
+      // All field initializers must be resolved as they could
+      // have an observable side-effect (and cannot be tree-shaken
+      // away).
+      fullyUse();
+    }
+  }
+
+  @override
+  bool get fullyUsed => hasRead && hasWrite;
+
+  @override
+  EnumSet<MemberUse> read() {
+    if (fullyUsed) {
+      return MemberUses.NONE;
+    }
+    hasRead = true;
+    return _pendingUse.removeAll(MemberUses.NORMAL_ONLY);
+  }
+
+  @override
+  EnumSet<MemberUse> write() {
+    if (fullyUsed) {
+      return MemberUses.NONE;
+    }
+    hasWrite = true;
+    return _pendingUse.removeAll(MemberUses.NORMAL_ONLY);
+  }
+
+  @override
+  EnumSet<MemberUse> invoke() => read();
+
+  @override
+  EnumSet<MemberUse> fullyUse() {
+    if (fullyUsed) {
+      return MemberUses.NONE;
+    }
+    hasRead = hasWrite = true;
+    return _pendingUse.removeAll(MemberUses.NORMAL_ONLY);
+  }
+}
+
+class _FinalFieldUsage extends _MemberUsage {
+  bool hasRead = false;
+
+  _FinalFieldUsage(FieldEntity field, {bool isNative: false})
+      : super.internal(field) {
+    if (!isNative) {
+      // All field initializers must be resolved as they could
+      // have an observable side-effect (and cannot be tree-shaken
+      // away).
+      read();
+    }
+  }
+
+  @override
+  bool get fullyUsed => hasRead;
+
+  @override
+  EnumSet<MemberUse> read() {
+    if (hasRead) {
+      return MemberUses.NONE;
+    }
+    hasRead = true;
+    return _pendingUse.removeAll(MemberUses.NORMAL_ONLY);
+  }
+
+  @override
+  EnumSet<MemberUse> invoke() => read();
+
+  @override
+  EnumSet<MemberUse> fullyUse() => read();
+}
+
+class _FunctionUsage extends _MemberUsage {
+  bool hasInvoke = false;
+  bool hasRead = false;
+
+  _FunctionUsage(FunctionEntity function) : super.internal(function);
+
+  EnumSet<MemberUse> get _originalUse => MemberUses.ALL;
+
+  @override
+  EnumSet<MemberUse> read() => fullyUse();
+
+  @override
+  EnumSet<MemberUse> invoke() {
+    if (hasInvoke) {
+      return MemberUses.NONE;
+    }
+    hasInvoke = true;
+    return _pendingUse
+        .removeAll(hasRead ? MemberUses.NONE : MemberUses.NORMAL_ONLY);
+  }
+
+  @override
+  EnumSet<MemberUse> fullyUse() {
+    if (hasInvoke) {
+      if (hasRead) {
+        return MemberUses.NONE;
+      }
+      hasRead = true;
+      return _pendingUse.removeAll(MemberUses.CLOSURIZE_ONLY);
+    } else if (hasRead) {
+      hasInvoke = true;
+      return _pendingUse.removeAll(MemberUses.NORMAL_ONLY);
+    } else {
+      hasRead = hasInvoke = true;
+      return _pendingUse.removeAll(MemberUses.ALL);
+    }
+  }
+
+  @override
+  bool get fullyUsed => hasInvoke && hasRead;
+}
+
+class _GetterUsage extends _MemberUsage {
+  bool hasRead = false;
+
+  _GetterUsage(FunctionEntity getter) : super.internal(getter);
+
+  @override
+  bool get fullyUsed => hasRead;
+
+  @override
+  EnumSet<MemberUse> read() {
+    if (hasRead) {
+      return MemberUses.NONE;
+    }
+    hasRead = true;
+    return _pendingUse.removeAll(MemberUses.NORMAL_ONLY);
+  }
+
+  @override
+  EnumSet<MemberUse> invoke() => read();
+
+  @override
+  EnumSet<MemberUse> fullyUse() => read();
+}
+
+class _SetterUsage extends _MemberUsage {
+  bool hasWrite = false;
+
+  _SetterUsage(FunctionEntity setter) : super.internal(setter);
+
+  @override
+  bool get fullyUsed => hasWrite;
+
+  @override
+  EnumSet<MemberUse> write() {
+    if (hasWrite) {
+      return MemberUses.NONE;
+    }
+    hasWrite = true;
+    return MemberUses.NORMAL_ONLY;
+  }
+
+  @override
+  EnumSet<MemberUse> fullyUse() => write();
+}
+
+/// Enum class for the possible kind of use of [MemberEntity] objects.
+enum MemberUse { NORMAL, CLOSURIZE }
+
+/// Common [EnumSet]s used for [MemberUse].
+class MemberUses {
+  static const EnumSet<MemberUse> NONE = const EnumSet<MemberUse>.fixed(0);
+  static const EnumSet<MemberUse> NORMAL_ONLY =
+      const EnumSet<MemberUse>.fixed(1);
+  static const EnumSet<MemberUse> CLOSURIZE_ONLY =
+      const EnumSet<MemberUse>.fixed(2);
+  static const EnumSet<MemberUse> ALL = const EnumSet<MemberUse>.fixed(3);
+}
+
+typedef void MemberUsed(MemberEntity member, EnumSet<MemberUse> useSet);
+
+/// Registry for the observed use of a class [entity] in the open world.
+// TODO(johnniwinther): Merge this with [InstantiationInfo].
+class _ClassUsage extends _AbstractUsage<ClassUse> {
+  bool isInstantiated = false;
+  bool isImplemented = false;
+
+  final ClassEntity cls;
+
+  _ClassUsage(this.cls);
+
+  EnumSet<ClassUse> instantiate() {
+    if (isInstantiated) {
+      return ClassUses.NONE;
+    }
+    isInstantiated = true;
+    return _pendingUse.removeAll(ClassUses.INSTANTIATED_ONLY);
+  }
+
+  EnumSet<ClassUse> implement() {
+    if (isImplemented) {
+      return ClassUses.NONE;
+    }
+    isImplemented = true;
+    return _pendingUse.removeAll(ClassUses.IMPLEMENTED_ONLY);
+  }
+
+  @override
+  EnumSet<ClassUse> get _originalUse => ClassUses.ALL;
+
+  String toString() => cls.toString();
+}
+
+/// Enum class for the possible kind of use of [ClassEntity] objects.
+enum ClassUse { INSTANTIATED, IMPLEMENTED }
+
+/// Common [EnumSet]s used for [ClassUse].
+class ClassUses {
+  static const EnumSet<ClassUse> NONE = const EnumSet<ClassUse>.fixed(0);
+  static const EnumSet<ClassUse> INSTANTIATED_ONLY =
+      const EnumSet<ClassUse>.fixed(1);
+  static const EnumSet<ClassUse> IMPLEMENTED_ONLY =
+      const EnumSet<ClassUse>.fixed(2);
+  static const EnumSet<ClassUse> ALL = const EnumSet<ClassUse>.fixed(3);
+}
+
+typedef void ClassUsed(ClassEntity cls, EnumSet<ClassUse> useSet);
diff --git a/pkg/compiler/lib/src/util/enumset.dart b/pkg/compiler/lib/src/util/enumset.dart
index ab4dcc86..31fef3c 100644
--- a/pkg/compiler/lib/src/util/enumset.dart
+++ b/pkg/compiler/lib/src/util/enumset.dart
@@ -35,9 +35,27 @@
   /// Adds [enumValue] to this set.
   void add(E enumValue);
 
+  /// Adds all enum values in [set] to this set.
+  void addAll(EnumSet<E> set);
+
   /// Removes [enumValue] from this set.
   void remove(E enumValue);
 
+  /// Removes all enum values in [set] from this set. The set of removed values
+  /// is returned.
+  EnumSet<E> removeAll(EnumSet<E> set);
+
+  /// Returns a new set containing all values in both this and the [other] set.
+  EnumSet<E> intersection(EnumSet<E> other) {
+    return new EnumSet.fromValue(value & other.value);
+  }
+
+  /// Returns a new set containing all values in this set that are not in the
+  /// [other] set.
+  EnumSet<E> minus(EnumSet<E> other) {
+    return new EnumSet.fromValue(value & ~other.value);
+  }
+
   /// Clears this set.
   void clear();
 
@@ -67,6 +85,9 @@
   /// Returns `true` if this set is empty.
   bool get isEmpty => value == 0;
 
+  /// Returns `true` if this set is not empty.
+  bool get isNotEmpty => value != 0;
+
   int get hashCode => value.hashCode * 19;
 
   bool operator ==(other) {
@@ -103,16 +124,32 @@
     values.forEach(add);
   }
 
+  @override
   int get value => _value;
 
+  @override
   void add(E enumValue) {
     _value |= 1 << (enumValue as dynamic).index;
   }
 
+  @override
+  void addAll(EnumSet<E> set) {
+    _value |= set.value;
+  }
+
+  @override
   void remove(E enumValue) {
     _value &= ~(1 << (enumValue as dynamic).index);
   }
 
+  @override
+  EnumSet<E> removeAll(EnumSet<E> set) {
+    int removed = _value & set.value;
+    _value &= ~set.value;
+    return new EnumSet<E>.fromValue(removed);
+  }
+
+  @override
   void clear() {
     _value = 0;
   }
@@ -142,6 +179,11 @@
   }
 
   @override
+  void addAll(EnumSet<E> set) {
+    throw new UnsupportedError('EnumSet.addAll');
+  }
+
+  @override
   void clear() {
     throw new UnsupportedError('EnumSet.clear');
   }
@@ -150,6 +192,11 @@
   void remove(E enumValue) {
     throw new UnsupportedError('EnumSet.remove');
   }
+
+  @override
+  EnumSet<E> removeAll(EnumSet<E> set) {
+    throw new UnsupportedError('EnumSet.removeAll');
+  }
 }
 
 class _EnumSetIterable<E> extends IterableBase<E> {
diff --git a/pkg/compiler/lib/src/world.dart b/pkg/compiler/lib/src/world.dart
index c406d07..2ddfbd8 100644
--- a/pkg/compiler/lib/src/world.dart
+++ b/pkg/compiler/lib/src/world.dart
@@ -1124,7 +1124,7 @@
       return true;
     }
     if (element.isInstanceMember) {
-      return !resolverWorld.hasInvokedSetter(element, this) &&
+      return !resolverWorld.hasInvokedSetter(element) &&
           !resolverWorld.fieldSetters.contains(element);
     }
     return false;
diff --git a/pkg/compiler/pubspec.yaml b/pkg/compiler/pubspec.yaml
index 07f759a..e0f3df7d 100644
--- a/pkg/compiler/pubspec.yaml
+++ b/pkg/compiler/pubspec.yaml
@@ -15,7 +15,8 @@
     path: ../../pkg/kernel
   sdk_library_metadata:
     path: ../../sdk/lib/_internal/sdk_library_metadata
-  dart2js_info: ^0.3.0
+  dart2js_info:
+    path: ../../third_party/pkg/dart2js_info
   lookup_map:
     path: ../lookup_map
 
diff --git a/pkg/dev_compiler/doc/GENERIC_METHODS.md b/pkg/dev_compiler/doc/GENERIC_METHODS.md
index 7c21f94..a61748c 100644
--- a/pkg/dev_compiler/doc/GENERIC_METHODS.md
+++ b/pkg/dev_compiler/doc/GENERIC_METHODS.md
@@ -1,229 +1,188 @@
-# Prototype Syntax for Generic Methods
+# Using Generic Methods
 
-Generic methods are a [proposed addition to the Dart language](https://github.com/leafpetersen/dep-generic-methods/blob/master/proposal.md).
+**Note: For historical reasons, this feature is called "generic methods", but it
+applies equally well to instance methods, static methods, top-level functions,
+local functions, and even lambda expressions.**
 
-This is a summary of the current (as of January 2016) comment-based generic
-method syntax supported by the analyzer strong mode and the Dart Dev Compiler.
-The comment-based syntax essentially uses the proposed actual generic method
-syntax, but wraps it in comments.  This allows developers to experiment with
-generic methods while still ensuring that their code runs on all platforms while
-generic methods are still being evaluated for inclusion into the language.
+Initially a [proposal][], generic methods are on their way to being fully
+supported in Dart. Here is how to use them.
 
-## Declaring generic method parameters
+[proposal]: https://github.com/leafpetersen/dep-generic-methods/blob/master/proposal.md
 
-Generic method parameters are listed using a block comment after the method or
-function name, inside of angle brackets.
+When they were still being prototyped, an [older comment-based syntax was
+designed][old] so that the static analysis could be implemented and tested
+before the VM and compilers needed to worry about the syntax. Now that real
+syntax is allowed everywhere, this doc has been updated.
+
+[old]: GENERIC_METHOD_COMMENTS.md
+
+## Declaring generic methods
+
+Type parameters for generic methods are listed after the method or function
+name, inside angle brackets:
 
 ```dart
-// This declares a function which takes two unused generic method parameters
-int f/*<S, T>*/(int x) => 3;
+/// Takes two type parameters, [K] and [V].
+Map<K, V> singletonMap<K, V>(K key, V value) {
+  return <K, V>{ key, value };
+}
 ```
 
-As with classes, you can put bounds on type parameters.
+As with classes, you can put bounds on type parameters:
 
 ```dart
-// This declares a function which takes two unused generic method parameters
-// The first parameter (S) must extend num
-// The second parameter (T) must extend List<S>
-int f/*<S extends num, T extends List<S>>*/(int x) => 3;
+/// Takes a list of two numbers of some num-derived type [T].
+T sumPair<T extends num>(List<T> items) {
+  return items[0] + items[1];
+}
 ```
 
 Class methods (instance and static) can be declared to take generic parameters
-in the same way.
+in the same way:
 
 ```dart
 class C {
-  static int f/*<S, T>*/(int x) => 3;
-  int m/*<S, T>*/(int x) => 3;
+  static int f<S, T>(int x) => 3;
+  int m<S, T>(int x) => 3;
 }
 ```
 
-Function typed parameters, local functions, and function expressions can also be
-declared to take generic parameters.
+This even works for function-typed parameters, local functions, and function
+expressions:
 
 ```dart
-// foo takes a generic method as a parameter
-void foo(int f/*<S>*/(int x)) {}
+/// Takes a generic method as a parameter [callback].
+void functionTypedParameter(T callback<T>(T thing)) {}
 
-// foo declares a local generic function
-void foo() {
-  int f/*<S>*/(int x) => 3;
-  return;
+// Declares a local generic function `itself`.
+void localFunction() {
+  T itself<T>(T thing) => thing;
 }
 
-// foo binds a generic function expression to a local variable.
-void foo() {
-  var x = /*<S>*/(int x) => x;
+// Binds a generic function expression to a local variable.
+void functionExpression() {
+  var lambda = <T>(T thing) => thing;
 }
 ```
 
-We do not currently support a way to declare a function as returning a generic
-function.  This will eventually be supported using something analogous to Dart
-typedefs.
+We do not currently support a way to declare a function as *returning* a generic
+function. This will eventually be supported using a `typedef`.
 
-## Using generic method parameters
+## Using generic method type parameters
 
-The previous examples declared generic method parameters, but did not use them.
-You can use a generic method parameter `T` anywhere that a type is expected in
-Dart by writing a type followed by `/*=T*/`.  So for example, `dynamic /*=T*/`
-will be interpreted as `dynamic` by all non-strong mode tools, but will be
-interpreted as `T` by strong mode.  In places where it is valid to leave off a
-type, simply writing `/*=T*/` will be interpreted as `dynamic` by non-strong
-mode tools, but will be interpreted as `T` by strong mode.  For example:
+You've seen some examples already, but you can use a generic type parameter
+almost anywhere you would expect in a generic method.
+
+* Inside the method's parameter list:
+
+    ```dart
+    takeThing<T>(T thing) { ... }
+    //           ^-- Here.
+    ```
+
+* Inside type annotations in the body of the method:
+
+    ```dart
+    useThing<T>() {
+      T thing = getThing();
+    //^-- Here.
+      List<T> pair = [thing, thing];
+      //   ^-- And here.
+    }
+    ```
+
+* In the return type of the method:
+
+    ```dart
+      T itself<T>(T thing) => thing;
+    //^-- Here.
+    ```
+
+* As type arguments in generic classes and method calls:
+
+    ```dart
+    useThing<T>(T thing) {
+      var pair = <T>[thing, thing];
+      //          ^-- Here.
+      var set = new Set<T>()..add(thing);
+      //                ^-- And here.
+    }
+    ```
+
+    Note that generic methods are not yet supported *at runtime* on the VM and
+    dartjs. On those platforms, uses of generic method type arguments are
+    treated like `dynamic` today. So in this example, `pair`'s reified type at
+    runtime will be `List<dynamic>` and `set` will be `Set<dynamic>`.
+
+There are two places you *cannot* use a generic method type parameter. Both are
+because the VM and dart2js don't support reifying generic method type arguments
+yet. Since these expressions wouldn't do what you want, we've temporarily
+defined them to be an error:
+
+* As the right-hand side of an `is` or `is!` expression.
+
+    ```dart
+    testType<T>(object) {
+      print(object is T);
+      //              ^-- Error!
+      print(object is! T);
+      //               ^-- Error!
+    }
+    ```
+
+* As a type literal:
+
+    ```dart
+    printType<T>() {
+      Type t = T;
+      //       ^-- Error!
+      print(t);
+    }
+    ```
+
+Once we have full runtime support for generic methods, these will be allowed.
+
+## Calling generic methods
+
+Most of the time, when you call a generic method, you can leave off the type
+arguments and strong mode's type inference will fill them in for you
+automatically. For example:
 
 ```dart
-// foo is a generic method which takes a single generic method parameter S.
-// In strong mode, the parameter x will have type S, and the return type will
-// be S
-// In normal mode, the parameter x will have type dynamic, and the return
-// type will be dynamic.
-dynamic/*=S*/ foo/*<S>*/(dynamic/*=S*/ x) { return x; }
+var fruits = ["apple", "banana", "cherry"];
+var lengths = fruits.map((fruit) => fruit.length);
 ```
 
-This can be written more concisely by leaving off the `dynamic`.
+The `map()` method on Iterable is now generic and takes a type parameter for the
+element type of the returned sequence:
 
 ```dart
-/*=S*/ foo/*<S>*/(/*=S*/ x) {return x;}
-```
+class Iterable<T> {
+  Iterable<S> map<S>(S transform(T element)) { ... }
 
-You can also put a type to the left of the `/*=T/`. This type will be used
-for all non-strong mode tools. For example:
-
-```dart
-// This method works with `int`, `double`, or `num`. The return type will
-// match the type of the parameters.
-num/*=T*/ pickAtRandom/*<T extends num>*/(num/*=T*/ x, num/*=T*/ y) { ... }
-```
-
-
-Note that the generic parameter is in scope in the return type of the function,
-in the argument list of the function, and in the body of the function.  When
-declaring local variables and parameters, you can also use the `/*=T*/` syntax with `var`.
-
-```dart
-// foo is a generic method that takes a single generic parameter S, and a value
-// x of type S
-void foo/*<S>*/(var /*=S*/ x) {
-  // In strong mode, y will also have type S
-  var /*=S*/ y = x;
-
-  // In strong mode, z will also have type S
-  dynamic /*=S*/ z = y;
+  // Other stuff...
 }
 ```
 
-Anywhere that a type literal is expected, you can also use the `/*=T*/` syntax to
-produce a type literal from the generic method parameter.
+In this example, the type checker:
+
+1. Infers `List<String>` for the type of `fruits` based on the elements in the
+   list literal.
+2. That lets it infer `String` for the type of the lambda parameter `fruit`
+   passed to `map()`.
+3. Then, from the result of calling `.length`, it infers the return type of the
+   lambda to be `int`.
+4. That in turn is used to fill in the type argument to the call to `map()` as
+   `int`, and the resulting sequence is an `Iterable<int>`.
+
+If inference *isn't* able to fill in a type argument for you, it uses `dynamic`
+instead. If that isn't what you want, or it infers a type you don't want, you
+can always pass them explicitly:
 
 ```dart
-void foo/*<S>*/(/*=S*/ x) {
-  // In strong mode, s will get the type literal for S
-  Type s = dynamic /*=S*/;
+// Explicitly give a type so that we don't infer "int".
+var lengths = fruits.map<num>((fruit) => fruit.length).toList();
 
-  // In strong mode, this attempts to cast 3 as type S
-  var y = (3 as dynamic /*=S*/);
-}
-```
-
-You can use the `/*=T*/` syntax to replace any type with a generic type
-parameter, but you will usually want to replace `dynamic`. Otherwise, since the
-original type is used at runtime, it may cause checked mode errors:
-
-```dart
-List/*<T>*/ makeList/*<T extends num>*/() {
-  return new List<num /*=T*/>();
-}
-
-void main() {
-  List<int> list = makeList/*<int>*/(); // <-- Fails here.
-}
-```
-
-This program checks without error in strong mode but fails at runtime in checked
-mode since the list that gets created is a `List<num>`. A better choice is:
-
-```dart
-List/*<T>*/ makeList/*<T extends num>*/() {
-  return new List/*<T>*/();
-}
-
-void main() {
-  List<int> list = makeList/*<int>*/();
-}
-```
-
-## Instantiating generic classes with generic method parameters
-
-You can use generic method parameters to instantiate generic classes using the
-same `/*=T*/` syntax.
-
-```dart
-// foo is a generic method which returns a List<S> in strong mode,
-// but which returns List<dynamic> in normal mode.
-List<dynamic /*=S*/> foo/*<S>*/(/*=S*/ x) {
-   // l0 is a list literal whose reified type will be List<S> in strong mode,
-   // and List<dynamic> in normal mode.
-   var l0 = <dynamic /*=S*/>[x];
-
-   // as above, but with a regular constructor.
-   var l1 = new List<dynamic /*=S*/>();
-   return l1;
-}
-```
-
-In most cases, the entire type argument list to the generic class can be
-enclosed in parentheses, eliminating the need for explicitly writing `dynamic`.
-
-```dart
-// This is another way of writing the same code as above
-List/*<S>*/ foo/*<S>*/(/*=S*/ x) {
-   // The shorthand syntax is not yet supported for list and map literals
-   var l0 = <dynamic /*=S*/>[x];
-
-   // but with regular constructors you can use it
-   var l1 = new List/*<S>*/();
-   return l1;
-}
-```
-
-## Instantiating generic methods
-
-Generic methods can be called without passing type arguments.  Strong mode will
-attempt to infer the type arguments automatically.  If it is unable to do so,
-then the type arguments will be filled in with whatever their declared bounds
-are (by default, `dynamic`).
-
-```dart
-class C {
-  /*=S*/ inferableFromArgument/*<S>*/(/*=S*/ x) { return null;}
-  /*=S*/ notInferable/*<S>*/(int x) { return null;}
-}
-
-void main() {
-  C c = new C();
-  // This line will produce a type error, because strong mode will infer
-  // `int` as the generic argument to fill in for S
-  String x = c.inferableFromArgument(3);
-
-  // This line will not produce a type error, because strong mode is unable
-  // to infer a type and will fill in the type argument with `dynamic`.
-  String y = c.notInferable(3);
-}
-```
-
-In the case that strong mode cannot infer the generic type arguments, the same
-syntax that was shown above for instantiating generic classes can be used to
-instantiate generic methods explicitly.
-
-```dart
-void main() {
-  C c = new C();
-  // This line will produce a type error, because strong mode will infer
-  // `int` as the generic argument to fill in for S
-  String x = c.inferableFromArgument(3);
-
-  // This line will produce a type error in strong mode, because `int` is
-  // explicitly passed in as the argument to use for S
-  String y = c.notInferable/*<int>*/(3);
-}
+// So that we can later add doubles to the result.
+lengths.add(1.2);
 ```
diff --git a/pkg/dev_compiler/doc/GENERIC_METHOD_COMMENTS.md b/pkg/dev_compiler/doc/GENERIC_METHOD_COMMENTS.md
new file mode 100644
index 0000000..9050eab
--- /dev/null
+++ b/pkg/dev_compiler/doc/GENERIC_METHOD_COMMENTS.md
@@ -0,0 +1,237 @@
+# Prototype Syntax for Generic Methods
+
+**Note:** This documents the deprecated comment-based syntax for generic
+methods. New code should use the [much better real syntax][real]. This document
+is preserved in case you run into existing code still using the old syntax.
+
+[real]: GENERIC_METHODS.md
+
+---
+
+Generic methods are a [proposed addition to the Dart language](https://github.com/leafpetersen/dep-generic-methods/blob/master/proposal.md).
+
+This is a summary of the current (as of January 2016) comment-based generic
+method syntax supported by the analyzer strong mode and the Dart Dev Compiler.
+The comment-based syntax essentially uses the proposed actual generic method
+syntax, but wraps it in comments.  This allows developers to experiment with
+generic methods while still ensuring that their code runs on all platforms while
+generic methods are still being evaluated for inclusion into the language.
+
+## Declaring generic method parameters
+
+Generic method parameters are listed using a block comment after the method or
+function name, inside of angle brackets.
+
+```dart
+// This declares a function which takes two unused generic method parameters
+int f/*<S, T>*/(int x) => 3;
+```
+
+As with classes, you can put bounds on type parameters.
+
+```dart
+// This declares a function which takes two unused generic method parameters
+// The first parameter (S) must extend num
+// The second parameter (T) must extend List<S>
+int f/*<S extends num, T extends List<S>>*/(int x) => 3;
+```
+
+Class methods (instance and static) can be declared to take generic parameters
+in the same way.
+
+```dart
+class C {
+  static int f/*<S, T>*/(int x) => 3;
+  int m/*<S, T>*/(int x) => 3;
+}
+```
+
+Function typed parameters, local functions, and function expressions can also be
+declared to take generic parameters.
+
+```dart
+// foo takes a generic method as a parameter
+void foo(int f/*<S>*/(int x)) {}
+
+// foo declares a local generic function
+void foo() {
+  int f/*<S>*/(int x) => 3;
+  return;
+}
+
+// foo binds a generic function expression to a local variable.
+void foo() {
+  var x = /*<S>*/(int x) => x;
+}
+```
+
+We do not currently support a way to declare a function as returning a generic
+function.  This will eventually be supported using something analogous to Dart
+typedefs.
+
+## Using generic method parameters
+
+The previous examples declared generic method parameters, but did not use them.
+You can use a generic method parameter `T` anywhere that a type is expected in
+Dart by writing a type followed by `/*=T*/`.  So for example, `dynamic /*=T*/`
+will be interpreted as `dynamic` by all non-strong mode tools, but will be
+interpreted as `T` by strong mode.  In places where it is valid to leave off a
+type, simply writing `/*=T*/` will be interpreted as `dynamic` by non-strong
+mode tools, but will be interpreted as `T` by strong mode.  For example:
+
+```dart
+// foo is a generic method which takes a single generic method parameter S.
+// In strong mode, the parameter x will have type S, and the return type will
+// be S
+// In normal mode, the parameter x will have type dynamic, and the return
+// type will be dynamic.
+dynamic/*=S*/ foo/*<S>*/(dynamic/*=S*/ x) { return x; }
+```
+
+This can be written more concisely by leaving off the `dynamic`.
+
+```dart
+/*=S*/ foo/*<S>*/(/*=S*/ x) {return x;}
+```
+
+You can also put a type to the left of the `/*=T/`. This type will be used
+for all non-strong mode tools. For example:
+
+```dart
+// This method works with `int`, `double`, or `num`. The return type will
+// match the type of the parameters.
+num/*=T*/ pickAtRandom/*<T extends num>*/(num/*=T*/ x, num/*=T*/ y) { ... }
+```
+
+
+Note that the generic parameter is in scope in the return type of the function,
+in the argument list of the function, and in the body of the function.  When
+declaring local variables and parameters, you can also use the `/*=T*/` syntax with `var`.
+
+```dart
+// foo is a generic method that takes a single generic parameter S, and a value
+// x of type S
+void foo/*<S>*/(var /*=S*/ x) {
+  // In strong mode, y will also have type S
+  var /*=S*/ y = x;
+
+  // In strong mode, z will also have type S
+  dynamic /*=S*/ z = y;
+}
+```
+
+Anywhere that a type literal is expected, you can also use the `/*=T*/` syntax to
+produce a type literal from the generic method parameter.
+
+```dart
+void foo/*<S>*/(/*=S*/ x) {
+  // In strong mode, s will get the type literal for S
+  Type s = dynamic /*=S*/;
+
+  // In strong mode, this attempts to cast 3 as type S
+  var y = (3 as dynamic /*=S*/);
+}
+```
+
+You can use the `/*=T*/` syntax to replace any type with a generic type
+parameter, but you will usually want to replace `dynamic`. Otherwise, since the
+original type is used at runtime, it may cause checked mode errors:
+
+```dart
+List/*<T>*/ makeList/*<T extends num>*/() {
+  return new List<num /*=T*/>();
+}
+
+void main() {
+  List<int> list = makeList/*<int>*/(); // <-- Fails here.
+}
+```
+
+This program checks without error in strong mode but fails at runtime in checked
+mode since the list that gets created is a `List<num>`. A better choice is:
+
+```dart
+List/*<T>*/ makeList/*<T extends num>*/() {
+  return new List/*<T>*/();
+}
+
+void main() {
+  List<int> list = makeList/*<int>*/();
+}
+```
+
+## Instantiating generic classes with generic method parameters
+
+You can use generic method parameters to instantiate generic classes using the
+same `/*=T*/` syntax.
+
+```dart
+// foo is a generic method which returns a List<S> in strong mode,
+// but which returns List<dynamic> in normal mode.
+List<dynamic /*=S*/> foo/*<S>*/(/*=S*/ x) {
+   // l0 is a list literal whose reified type will be List<S> in strong mode,
+   // and List<dynamic> in normal mode.
+   var l0 = <dynamic /*=S*/>[x];
+
+   // as above, but with a regular constructor.
+   var l1 = new List<dynamic /*=S*/>();
+   return l1;
+}
+```
+
+In most cases, the entire type argument list to the generic class can be
+enclosed in parentheses, eliminating the need for explicitly writing `dynamic`.
+
+```dart
+// This is another way of writing the same code as above
+List/*<S>*/ foo/*<S>*/(/*=S*/ x) {
+   // The shorthand syntax is not yet supported for list and map literals
+   var l0 = <dynamic /*=S*/>[x];
+
+   // but with regular constructors you can use it
+   var l1 = new List/*<S>*/();
+   return l1;
+}
+```
+
+## Instantiating generic methods
+
+Generic methods can be called without passing type arguments.  Strong mode will
+attempt to infer the type arguments automatically.  If it is unable to do so,
+then the type arguments will be filled in with whatever their declared bounds
+are (by default, `dynamic`).
+
+```dart
+class C {
+  /*=S*/ inferableFromArgument/*<S>*/(/*=S*/ x) { return null;}
+  /*=S*/ notInferable/*<S>*/(int x) { return null;}
+}
+
+void main() {
+  C c = new C();
+  // This line will produce a type error, because strong mode will infer
+  // `int` as the generic argument to fill in for S
+  String x = c.inferableFromArgument(3);
+
+  // This line will not produce a type error, because strong mode is unable
+  // to infer a type and will fill in the type argument with `dynamic`.
+  String y = c.notInferable(3);
+}
+```
+
+In the case that strong mode cannot infer the generic type arguments, the same
+syntax that was shown above for instantiating generic classes can be used to
+instantiate generic methods explicitly.
+
+```dart
+void main() {
+  C c = new C();
+  // This line will produce a type error, because strong mode will infer
+  // `int` as the generic argument to fill in for S
+  String x = c.inferableFromArgument(3);
+
+  // This line will produce a type error in strong mode, because `int` is
+  // explicitly passed in as the argument to use for S
+  String y = c.notInferable/*<int>*/(3);
+}
+```
diff --git a/pkg/dev_compiler/lib/js/amd/dart_sdk.js b/pkg/dev_compiler/lib/js/amd/dart_sdk.js
index abb592c..41eef01 100644
--- a/pkg/dev_compiler/lib/js/amd/dart_sdk.js
+++ b/pkg/dev_compiler/lib/js/amd/dart_sdk.js
@@ -643,7 +643,6 @@
   let dynamic__Todynamic = () => (dynamic__Todynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic], [dart.dynamic])))();
   let dynamicTo_Future = () => (dynamicTo_Future = dart.constFn(dart.definiteFunctionType(async._Future, [dart.dynamic])))();
   let _AsyncCallbackTovoid = () => (_AsyncCallbackTovoid = dart.constFn(dart.definiteFunctionType(dart.void, [async._AsyncCallback])))();
-  let FnTodynamic = () => (FnTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [VoidTovoid()])))();
   let _NotificationHandlerToFuture = () => (_NotificationHandlerToFuture = dart.constFn(dart.definiteFunctionType(async.Future, [async._NotificationHandler])))();
   let dynamicAndStackTraceTodynamic = () => (dynamicAndStackTraceTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic, core.StackTrace])))();
   let dynamic__Tovoid = () => (dynamic__Tovoid = dart.constFn(dart.definiteFunctionType(dart.void, [dart.dynamic], [core.StackTrace])))();
@@ -1190,7 +1189,7 @@
   };
   const _wrappedType = Symbol('_wrappedType');
   dart.unwrapType = function(obj) {
-    return dart.dload(obj, _wrappedType);
+    return obj[_wrappedType];
   };
   dart._getRuntimeType = function(value) {
     return value[dart._runtimeType];
@@ -1900,14 +1899,12 @@
     if (!condition) dart.throwAssertionError();
   };
   dart.throw = function(obj) {
-    if (obj != null && (typeof obj == 'object' || typeof obj == 'function')) {
-      dart._stack.set(obj, new Error());
-    }
+    dart._stack = new Error();
     throw obj;
   };
   dart.getError = function(exception) {
-    var stack = dart._stack.get(exception);
-    return stack !== void 0 ? stack : exception;
+    var stack = dart._stack;
+    return stack !== null ? stack : exception;
   };
   dart.stackPrint = function(exception) {
     var error = dart.getError(exception);
@@ -2665,7 +2662,7 @@
       return false;
     });
   })();
-  dart._stack = new WeakMap();
+  dart._stack = null;
   dart._value = Symbol("_value");
   dart.constants = new Map();
   dart.constantLists = new Map();
@@ -17300,6 +17297,8 @@
     return end;
   };
   dart.fn(_native_typed_data._checkValidRange, intAndintAndintToint());
+  async._Callback = dart.typedef('_Callback', () => dart.functionType(dart.void, []));
+  async._TakeCallback = dart.typedef('_TakeCallback', () => dart.functionType(dart.void, [async._Callback]));
   async._invokeErrorHandler = function(errorHandler, error, stackTrace) {
     if (async.ZoneBinaryCallback.is(errorHandler)) {
       return dart.dcall(errorHandler, error, stackTrace);
@@ -17737,7 +17736,7 @@
         dart.assert(!dart.test(this[_inCallback]));
         let wasInputPaused = this[_isInputPaused];
         this[_state] = (dart.notNull(this[_state]) | async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
-        dart.dcall(callback);
+        callback();
         this[_state] = (dart.notNull(this[_state]) & ~async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
         this[_checkState](wasInputPaused);
       }
@@ -17818,7 +17817,7 @@
         [_sendData]: dart.definiteFunctionType(dart.void, [T]),
         [_sendError]: dart.definiteFunctionType(dart.void, [core.Object, core.StackTrace]),
         [_sendDone]: dart.definiteFunctionType(dart.void, []),
-        [_guardCallback]: dart.definiteFunctionType(dart.void, [dart.dynamic]),
+        [_guardCallback]: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
         [_checkState]: dart.definiteFunctionType(dart.void, [core.bool])
       }),
       sfields: () => ({
@@ -19637,7 +19636,7 @@
   dart.fn(async.scheduleMicrotask, _AsyncCallbackTovoid());
   async._AsyncRun = class _AsyncRun extends core.Object {
     static _scheduleImmediate(callback) {
-      dart.dcall(async._AsyncRun._scheduleImmediateClosure, callback);
+      async._AsyncRun._scheduleImmediateClosure(callback);
     }
     static _initializeScheduleImmediate() {
       if (self.scheduleImmediate != null) {
@@ -19651,7 +19650,7 @@
           _isolate_helper.leaveJsAsync();
           let f = storedCallback;
           storedCallback = null;
-          dart.dcall(f);
+          f();
         }
         dart.fn(internalCallback, dynamicTodynamic$());
         ;
@@ -19662,7 +19661,7 @@
           _isolate_helper.enterJsAsync();
           storedCallback = callback;
           div.firstChild ? div.removeChild(span) : div.appendChild(span);
-        }, FnTodynamic());
+        }, _AsyncCallbackTovoid());
       } else if (self.setImmediate != null) {
         return async._AsyncRun._scheduleImmediateWithSetImmediate;
       }
@@ -19693,10 +19692,10 @@
     }
   };
   dart.setSignature(async._AsyncRun, {
-    sfields: () => ({_scheduleImmediateClosure: core.Function}),
+    sfields: () => ({_scheduleImmediateClosure: async._TakeCallback}),
     statics: () => ({
       _scheduleImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
-      _initializeScheduleImmediate: dart.definiteFunctionType(core.Function, []),
+      _initializeScheduleImmediate: dart.definiteFunctionType(async._TakeCallback, []),
       _scheduleImmediateJsOverride: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
       _scheduleImmediateWithSetImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
       _scheduleImmediateWithTimer: dart.definiteFunctionType(dart.void, [VoidTovoid()])
@@ -20100,7 +20099,7 @@
         subscription[_setPendingEvents](pendingEvents);
         subscription[_guardCallback](dart.fn(() => {
           async._runGuarded(this.onListen);
-        }, VoidTodynamic$()));
+        }, VoidTovoid$()));
         return subscription;
       }
       [_recordCancel](subscription) {
diff --git a/pkg/dev_compiler/lib/js/common/dart_sdk.js b/pkg/dev_compiler/lib/js/common/dart_sdk.js
index e025ec5..e3d4b45 100644
--- a/pkg/dev_compiler/lib/js/common/dart_sdk.js
+++ b/pkg/dev_compiler/lib/js/common/dart_sdk.js
@@ -643,7 +643,6 @@
   let dynamic__Todynamic = () => (dynamic__Todynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic], [dart.dynamic])))();
   let dynamicTo_Future = () => (dynamicTo_Future = dart.constFn(dart.definiteFunctionType(async._Future, [dart.dynamic])))();
   let _AsyncCallbackTovoid = () => (_AsyncCallbackTovoid = dart.constFn(dart.definiteFunctionType(dart.void, [async._AsyncCallback])))();
-  let FnTodynamic = () => (FnTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [VoidTovoid()])))();
   let _NotificationHandlerToFuture = () => (_NotificationHandlerToFuture = dart.constFn(dart.definiteFunctionType(async.Future, [async._NotificationHandler])))();
   let dynamicAndStackTraceTodynamic = () => (dynamicAndStackTraceTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic, core.StackTrace])))();
   let dynamic__Tovoid = () => (dynamic__Tovoid = dart.constFn(dart.definiteFunctionType(dart.void, [dart.dynamic], [core.StackTrace])))();
@@ -1190,7 +1189,7 @@
   };
   const _wrappedType = Symbol('_wrappedType');
   dart.unwrapType = function(obj) {
-    return dart.dload(obj, _wrappedType);
+    return obj[_wrappedType];
   };
   dart._getRuntimeType = function(value) {
     return value[dart._runtimeType];
@@ -1900,14 +1899,12 @@
     if (!condition) dart.throwAssertionError();
   };
   dart.throw = function(obj) {
-    if (obj != null && (typeof obj == 'object' || typeof obj == 'function')) {
-      dart._stack.set(obj, new Error());
-    }
+    dart._stack = new Error();
     throw obj;
   };
   dart.getError = function(exception) {
-    var stack = dart._stack.get(exception);
-    return stack !== void 0 ? stack : exception;
+    var stack = dart._stack;
+    return stack !== null ? stack : exception;
   };
   dart.stackPrint = function(exception) {
     var error = dart.getError(exception);
@@ -2665,7 +2662,7 @@
       return false;
     });
   })();
-  dart._stack = new WeakMap();
+  dart._stack = null;
   dart._value = Symbol("_value");
   dart.constants = new Map();
   dart.constantLists = new Map();
@@ -17300,6 +17297,8 @@
     return end;
   };
   dart.fn(_native_typed_data._checkValidRange, intAndintAndintToint());
+  async._Callback = dart.typedef('_Callback', () => dart.functionType(dart.void, []));
+  async._TakeCallback = dart.typedef('_TakeCallback', () => dart.functionType(dart.void, [async._Callback]));
   async._invokeErrorHandler = function(errorHandler, error, stackTrace) {
     if (async.ZoneBinaryCallback.is(errorHandler)) {
       return dart.dcall(errorHandler, error, stackTrace);
@@ -17737,7 +17736,7 @@
         dart.assert(!dart.test(this[_inCallback]));
         let wasInputPaused = this[_isInputPaused];
         this[_state] = (dart.notNull(this[_state]) | async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
-        dart.dcall(callback);
+        callback();
         this[_state] = (dart.notNull(this[_state]) & ~async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
         this[_checkState](wasInputPaused);
       }
@@ -17818,7 +17817,7 @@
         [_sendData]: dart.definiteFunctionType(dart.void, [T]),
         [_sendError]: dart.definiteFunctionType(dart.void, [core.Object, core.StackTrace]),
         [_sendDone]: dart.definiteFunctionType(dart.void, []),
-        [_guardCallback]: dart.definiteFunctionType(dart.void, [dart.dynamic]),
+        [_guardCallback]: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
         [_checkState]: dart.definiteFunctionType(dart.void, [core.bool])
       }),
       sfields: () => ({
@@ -19637,7 +19636,7 @@
   dart.fn(async.scheduleMicrotask, _AsyncCallbackTovoid());
   async._AsyncRun = class _AsyncRun extends core.Object {
     static _scheduleImmediate(callback) {
-      dart.dcall(async._AsyncRun._scheduleImmediateClosure, callback);
+      async._AsyncRun._scheduleImmediateClosure(callback);
     }
     static _initializeScheduleImmediate() {
       if (self.scheduleImmediate != null) {
@@ -19651,7 +19650,7 @@
           _isolate_helper.leaveJsAsync();
           let f = storedCallback;
           storedCallback = null;
-          dart.dcall(f);
+          f();
         }
         dart.fn(internalCallback, dynamicTodynamic$());
         ;
@@ -19662,7 +19661,7 @@
           _isolate_helper.enterJsAsync();
           storedCallback = callback;
           div.firstChild ? div.removeChild(span) : div.appendChild(span);
-        }, FnTodynamic());
+        }, _AsyncCallbackTovoid());
       } else if (self.setImmediate != null) {
         return async._AsyncRun._scheduleImmediateWithSetImmediate;
       }
@@ -19693,10 +19692,10 @@
     }
   };
   dart.setSignature(async._AsyncRun, {
-    sfields: () => ({_scheduleImmediateClosure: core.Function}),
+    sfields: () => ({_scheduleImmediateClosure: async._TakeCallback}),
     statics: () => ({
       _scheduleImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
-      _initializeScheduleImmediate: dart.definiteFunctionType(core.Function, []),
+      _initializeScheduleImmediate: dart.definiteFunctionType(async._TakeCallback, []),
       _scheduleImmediateJsOverride: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
       _scheduleImmediateWithSetImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
       _scheduleImmediateWithTimer: dart.definiteFunctionType(dart.void, [VoidTovoid()])
@@ -20100,7 +20099,7 @@
         subscription[_setPendingEvents](pendingEvents);
         subscription[_guardCallback](dart.fn(() => {
           async._runGuarded(this.onListen);
-        }, VoidTodynamic$()));
+        }, VoidTovoid$()));
         return subscription;
       }
       [_recordCancel](subscription) {
diff --git a/pkg/dev_compiler/lib/js/es6/dart_sdk.js b/pkg/dev_compiler/lib/js/es6/dart_sdk.js
index 658981b..9583195 100644
--- a/pkg/dev_compiler/lib/js/es6/dart_sdk.js
+++ b/pkg/dev_compiler/lib/js/es6/dart_sdk.js
@@ -641,7 +641,6 @@
 let dynamic__Todynamic = () => (dynamic__Todynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic], [dart.dynamic])))();
 let dynamicTo_Future = () => (dynamicTo_Future = dart.constFn(dart.definiteFunctionType(async._Future, [dart.dynamic])))();
 let _AsyncCallbackTovoid = () => (_AsyncCallbackTovoid = dart.constFn(dart.definiteFunctionType(dart.void, [async._AsyncCallback])))();
-let FnTodynamic = () => (FnTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [VoidTovoid()])))();
 let _NotificationHandlerToFuture = () => (_NotificationHandlerToFuture = dart.constFn(dart.definiteFunctionType(async.Future, [async._NotificationHandler])))();
 let dynamicAndStackTraceTodynamic = () => (dynamicAndStackTraceTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic, core.StackTrace])))();
 let dynamic__Tovoid = () => (dynamic__Tovoid = dart.constFn(dart.definiteFunctionType(dart.void, [dart.dynamic], [core.StackTrace])))();
@@ -1188,7 +1187,7 @@
 };
 const _wrappedType = Symbol('_wrappedType');
 dart.unwrapType = function(obj) {
-  return dart.dload(obj, _wrappedType);
+  return obj[_wrappedType];
 };
 dart._getRuntimeType = function(value) {
   return value[dart._runtimeType];
@@ -1898,14 +1897,12 @@
   if (!condition) dart.throwAssertionError();
 };
 dart.throw = function(obj) {
-  if (obj != null && (typeof obj == 'object' || typeof obj == 'function')) {
-    dart._stack.set(obj, new Error());
-  }
+  dart._stack = new Error();
   throw obj;
 };
 dart.getError = function(exception) {
-  var stack = dart._stack.get(exception);
-  return stack !== void 0 ? stack : exception;
+  var stack = dart._stack;
+  return stack !== null ? stack : exception;
 };
 dart.stackPrint = function(exception) {
   var error = dart.getError(exception);
@@ -2663,7 +2660,7 @@
     return false;
   });
 })();
-dart._stack = new WeakMap();
+dart._stack = null;
 dart._value = Symbol("_value");
 dart.constants = new Map();
 dart.constantLists = new Map();
@@ -17298,6 +17295,8 @@
   return end;
 };
 dart.fn(_native_typed_data._checkValidRange, intAndintAndintToint());
+async._Callback = dart.typedef('_Callback', () => dart.functionType(dart.void, []));
+async._TakeCallback = dart.typedef('_TakeCallback', () => dart.functionType(dart.void, [async._Callback]));
 async._invokeErrorHandler = function(errorHandler, error, stackTrace) {
   if (async.ZoneBinaryCallback.is(errorHandler)) {
     return dart.dcall(errorHandler, error, stackTrace);
@@ -17735,7 +17734,7 @@
       dart.assert(!dart.test(this[_inCallback]));
       let wasInputPaused = this[_isInputPaused];
       this[_state] = (dart.notNull(this[_state]) | async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
-      dart.dcall(callback);
+      callback();
       this[_state] = (dart.notNull(this[_state]) & ~async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
       this[_checkState](wasInputPaused);
     }
@@ -17816,7 +17815,7 @@
       [_sendData]: dart.definiteFunctionType(dart.void, [T]),
       [_sendError]: dart.definiteFunctionType(dart.void, [core.Object, core.StackTrace]),
       [_sendDone]: dart.definiteFunctionType(dart.void, []),
-      [_guardCallback]: dart.definiteFunctionType(dart.void, [dart.dynamic]),
+      [_guardCallback]: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
       [_checkState]: dart.definiteFunctionType(dart.void, [core.bool])
     }),
     sfields: () => ({
@@ -19635,7 +19634,7 @@
 dart.fn(async.scheduleMicrotask, _AsyncCallbackTovoid());
 async._AsyncRun = class _AsyncRun extends core.Object {
   static _scheduleImmediate(callback) {
-    dart.dcall(async._AsyncRun._scheduleImmediateClosure, callback);
+    async._AsyncRun._scheduleImmediateClosure(callback);
   }
   static _initializeScheduleImmediate() {
     if (self.scheduleImmediate != null) {
@@ -19649,7 +19648,7 @@
         _isolate_helper.leaveJsAsync();
         let f = storedCallback;
         storedCallback = null;
-        dart.dcall(f);
+        f();
       }
       dart.fn(internalCallback, dynamicTodynamic());
       ;
@@ -19660,7 +19659,7 @@
         _isolate_helper.enterJsAsync();
         storedCallback = callback;
         div.firstChild ? div.removeChild(span) : div.appendChild(span);
-      }, FnTodynamic());
+      }, _AsyncCallbackTovoid());
     } else if (self.setImmediate != null) {
       return async._AsyncRun._scheduleImmediateWithSetImmediate;
     }
@@ -19691,10 +19690,10 @@
   }
 };
 dart.setSignature(async._AsyncRun, {
-  sfields: () => ({_scheduleImmediateClosure: core.Function}),
+  sfields: () => ({_scheduleImmediateClosure: async._TakeCallback}),
   statics: () => ({
     _scheduleImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
-    _initializeScheduleImmediate: dart.definiteFunctionType(core.Function, []),
+    _initializeScheduleImmediate: dart.definiteFunctionType(async._TakeCallback, []),
     _scheduleImmediateJsOverride: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
     _scheduleImmediateWithSetImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
     _scheduleImmediateWithTimer: dart.definiteFunctionType(dart.void, [VoidTovoid()])
@@ -20098,7 +20097,7 @@
       subscription[_setPendingEvents](pendingEvents);
       subscription[_guardCallback](dart.fn(() => {
         async._runGuarded(this.onListen);
-      }, VoidTodynamic()));
+      }, VoidTovoid()));
       return subscription;
     }
     [_recordCancel](subscription) {
diff --git a/pkg/dev_compiler/lib/js/legacy/dart_sdk.js b/pkg/dev_compiler/lib/js/legacy/dart_sdk.js
index 53d7785..49d9cf7 100644
--- a/pkg/dev_compiler/lib/js/legacy/dart_sdk.js
+++ b/pkg/dev_compiler/lib/js/legacy/dart_sdk.js
@@ -644,7 +644,6 @@
   let dynamic__Todynamic = () => (dynamic__Todynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic], [dart.dynamic])))();
   let dynamicTo_Future = () => (dynamicTo_Future = dart.constFn(dart.definiteFunctionType(async._Future, [dart.dynamic])))();
   let _AsyncCallbackTovoid = () => (_AsyncCallbackTovoid = dart.constFn(dart.definiteFunctionType(dart.void, [async._AsyncCallback])))();
-  let FnTodynamic = () => (FnTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [VoidTovoid()])))();
   let _NotificationHandlerToFuture = () => (_NotificationHandlerToFuture = dart.constFn(dart.definiteFunctionType(async.Future, [async._NotificationHandler])))();
   let dynamicAndStackTraceTodynamic = () => (dynamicAndStackTraceTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynamic, core.StackTrace])))();
   let dynamic__Tovoid = () => (dynamic__Tovoid = dart.constFn(dart.definiteFunctionType(dart.void, [dart.dynamic], [core.StackTrace])))();
@@ -1191,7 +1190,7 @@
   };
   const _wrappedType = Symbol('_wrappedType');
   dart.unwrapType = function(obj) {
-    return dart.dload(obj, _wrappedType);
+    return obj[_wrappedType];
   };
   dart._getRuntimeType = function(value) {
     return value[dart._runtimeType];
@@ -1901,14 +1900,12 @@
     if (!condition) dart.throwAssertionError();
   };
   dart.throw = function(obj) {
-    if (obj != null && (typeof obj == 'object' || typeof obj == 'function')) {
-      dart._stack.set(obj, new Error());
-    }
+    dart._stack = new Error();
     throw obj;
   };
   dart.getError = function(exception) {
-    var stack = dart._stack.get(exception);
-    return stack !== void 0 ? stack : exception;
+    var stack = dart._stack;
+    return stack !== null ? stack : exception;
   };
   dart.stackPrint = function(exception) {
     var error = dart.getError(exception);
@@ -2666,7 +2663,7 @@
       return false;
     });
   })();
-  dart._stack = new WeakMap();
+  dart._stack = null;
   dart._value = Symbol("_value");
   dart.constants = new Map();
   dart.constantLists = new Map();
@@ -17301,6 +17298,8 @@
     return end;
   };
   dart.fn(_native_typed_data._checkValidRange, intAndintAndintToint());
+  async._Callback = dart.typedef('_Callback', () => dart.functionType(dart.void, []));
+  async._TakeCallback = dart.typedef('_TakeCallback', () => dart.functionType(dart.void, [async._Callback]));
   async._invokeErrorHandler = function(errorHandler, error, stackTrace) {
     if (async.ZoneBinaryCallback.is(errorHandler)) {
       return dart.dcall(errorHandler, error, stackTrace);
@@ -17738,7 +17737,7 @@
         dart.assert(!dart.test(this[_inCallback]));
         let wasInputPaused = this[_isInputPaused];
         this[_state] = (dart.notNull(this[_state]) | async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
-        dart.dcall(callback);
+        callback();
         this[_state] = (dart.notNull(this[_state]) & ~async._BufferingStreamSubscription._STATE_IN_CALLBACK) >>> 0;
         this[_checkState](wasInputPaused);
       }
@@ -17819,7 +17818,7 @@
         [_sendData]: dart.definiteFunctionType(dart.void, [T]),
         [_sendError]: dart.definiteFunctionType(dart.void, [core.Object, core.StackTrace]),
         [_sendDone]: dart.definiteFunctionType(dart.void, []),
-        [_guardCallback]: dart.definiteFunctionType(dart.void, [dart.dynamic]),
+        [_guardCallback]: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
         [_checkState]: dart.definiteFunctionType(dart.void, [core.bool])
       }),
       sfields: () => ({
@@ -19638,7 +19637,7 @@
   dart.fn(async.scheduleMicrotask, _AsyncCallbackTovoid());
   async._AsyncRun = class _AsyncRun extends core.Object {
     static _scheduleImmediate(callback) {
-      dart.dcall(async._AsyncRun._scheduleImmediateClosure, callback);
+      async._AsyncRun._scheduleImmediateClosure(callback);
     }
     static _initializeScheduleImmediate() {
       if (self.scheduleImmediate != null) {
@@ -19652,7 +19651,7 @@
           _isolate_helper.leaveJsAsync();
           let f = storedCallback;
           storedCallback = null;
-          dart.dcall(f);
+          f();
         }
         dart.fn(internalCallback, dynamicTodynamic$());
         ;
@@ -19663,7 +19662,7 @@
           _isolate_helper.enterJsAsync();
           storedCallback = callback;
           div.firstChild ? div.removeChild(span) : div.appendChild(span);
-        }, FnTodynamic());
+        }, _AsyncCallbackTovoid());
       } else if (self.setImmediate != null) {
         return async._AsyncRun._scheduleImmediateWithSetImmediate;
       }
@@ -19694,10 +19693,10 @@
     }
   };
   dart.setSignature(async._AsyncRun, {
-    sfields: () => ({_scheduleImmediateClosure: core.Function}),
+    sfields: () => ({_scheduleImmediateClosure: async._TakeCallback}),
     statics: () => ({
       _scheduleImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
-      _initializeScheduleImmediate: dart.definiteFunctionType(core.Function, []),
+      _initializeScheduleImmediate: dart.definiteFunctionType(async._TakeCallback, []),
       _scheduleImmediateJsOverride: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
       _scheduleImmediateWithSetImmediate: dart.definiteFunctionType(dart.void, [VoidTovoid()]),
       _scheduleImmediateWithTimer: dart.definiteFunctionType(dart.void, [VoidTovoid()])
@@ -20101,7 +20100,7 @@
         subscription[_setPendingEvents](pendingEvents);
         subscription[_guardCallback](dart.fn(() => {
           async._runGuarded(this.onListen);
-        }, VoidTodynamic$()));
+        }, VoidTovoid$()));
         return subscription;
       }
       [_recordCancel](subscription) {
diff --git a/pkg/dev_compiler/lib/sdk/ddc_sdk.sum b/pkg/dev_compiler/lib/sdk/ddc_sdk.sum
index 6286c3e..3eb77ba 100644
--- a/pkg/dev_compiler/lib/sdk/ddc_sdk.sum
+++ b/pkg/dev_compiler/lib/sdk/ddc_sdk.sum
Binary files differ
diff --git a/pkg/dev_compiler/lib/src/compiler/ast_builder.dart b/pkg/dev_compiler/lib/src/compiler/ast_builder.dart
index 76d534d..46c57b1 100644
--- a/pkg/dev_compiler/lib/src/compiler/ast_builder.dart
+++ b/pkg/dev_compiler/lib/src/compiler/ast_builder.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/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/src/dart/ast/token.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart';
@@ -102,13 +103,13 @@
   static PropertyAccess propertyAccess(
       Expression target, SimpleIdentifier name) {
     var p = new Token(TokenType.PERIOD, 0);
-    return new PropertyAccess(target, p, name);
+    return astFactory.propertyAccess(target, p, name);
   }
 
   static MethodInvocation methodInvoke(Expression target, SimpleIdentifier name,
       TypeArgumentList typeArguments, NodeList<Expression> args) {
     var p = new Token(TokenType.PERIOD, 0);
-    return new MethodInvocation(
+    return astFactory.methodInvocation(
         target, p, name, typeArguments, argumentList(args));
   }
 
@@ -359,8 +360,8 @@
       [Expression init]) {
     var eqToken = init != null ? new Token(TokenType.EQ, 0) : null;
     var varToken = new KeywordToken(Keyword.VAR, 0);
-    return new VariableDeclarationList(null, null, varToken, null,
-        [new VariableDeclaration(name, eqToken, init)]);
+    return astFactory.variableDeclarationList(null, null, varToken, null,
+        [astFactory.variableDeclaration(name, eqToken, init)]);
   }
 
   static VariableDeclarationStatement variableStatement(SimpleIdentifier name,
@@ -372,7 +373,7 @@
   static InstanceCreationExpression instanceCreation(
       ConstructorName ctor, List<Expression> args) {
     var newToken = new KeywordToken(Keyword.NEW, 0);
-    return new InstanceCreationExpression(
+    return astFactory.instanceCreationExpression(
         newToken, ctor, RawAstBuilder.argumentList(args));
   }
 }
@@ -383,112 +384,113 @@
   static ConstructorName constructorName(TypeName type,
       [SimpleIdentifier name]) {
     Token period = name != null ? new Token(TokenType.PERIOD, 0) : null;
-    return new ConstructorName(type, period, name);
+    return astFactory.constructorName(type, period, name);
   }
 
   static SimpleIdentifier identifierFromString(String name) {
     StringToken token = new SyntheticStringToken(TokenType.IDENTIFIER, name, 0);
-    return new SimpleIdentifier(token);
+    return astFactory.simpleIdentifier(token);
   }
 
   static PrefixedIdentifier prefixedIdentifier(
       SimpleIdentifier pre, SimpleIdentifier id) {
     Token period = new Token(TokenType.PERIOD, 0);
-    return new PrefixedIdentifier(pre, period, id);
+    return astFactory.prefixedIdentifier(pre, period, id);
   }
 
   static TypeParameter typeParameter(SimpleIdentifier name,
       [TypeName bound = null]) {
     Token keyword =
         (bound == null) ? null : new KeywordToken(Keyword.EXTENDS, 0);
-    return new TypeParameter(null, null, name, keyword, bound);
+    return astFactory.typeParameter(null, null, name, keyword, bound);
   }
 
   static TypeParameterList typeParameterList(List<TypeParameter> params) {
     Token lb = new Token(TokenType.LT, 0);
     Token rb = new Token(TokenType.GT, 0);
-    return new TypeParameterList(lb, params, rb);
+    return astFactory.typeParameterList(lb, params, rb);
   }
 
   static TypeArgumentList typeArgumentList(List<TypeName> args) {
     Token lb = new Token(TokenType.LT, 0);
     Token rb = new Token(TokenType.GT, 0);
-    return new TypeArgumentList(lb, args, rb);
+    return astFactory.typeArgumentList(lb, args, rb);
   }
 
   static ArgumentList argumentList(List<Expression> args) {
     Token lp = new BeginToken(TokenType.OPEN_PAREN, 0);
     Token rp = new Token(TokenType.CLOSE_PAREN, 0);
-    return new ArgumentList(lp, args, rp);
+    return astFactory.argumentList(lp, args, rp);
   }
 
   static TypeName typeName(Identifier id, TypeArgumentList l) {
-    return new TypeName(id, l);
+    return astFactory.typeName(id, l);
   }
 
   static FunctionTypeAlias functionTypeAlias(TypeName ret,
       SimpleIdentifier name, TypeParameterList tps, FormalParameterList fps) {
     Token semi = new Token(TokenType.SEMICOLON, 0);
     Token td = new KeywordToken(Keyword.TYPEDEF, 0);
-    return new FunctionTypeAlias(null, null, td, ret, name, tps, fps, semi);
+    return astFactory.functionTypeAlias(
+        null, null, td, ret, name, tps, fps, semi);
   }
 
   static BooleanLiteral booleanLiteral(bool b) {
     var k = new KeywordToken(b ? Keyword.TRUE : Keyword.FALSE, 0);
-    return new BooleanLiteral(k, b);
+    return astFactory.booleanLiteral(k, b);
   }
 
   static NullLiteral nullLiteral() {
     var n = new KeywordToken(Keyword.NULL, 0);
-    return new NullLiteral(n);
+    return astFactory.nullLiteral(n);
   }
 
   static IntegerLiteral integerLiteral(int i) {
     StringToken token = new StringToken(TokenType.INT, '$i', 0);
-    return new IntegerLiteral(token, i);
+    return astFactory.integerLiteral(token, i);
   }
 
   static SimpleStringLiteral simpleStringLiteral(String s) {
     StringToken token = new StringToken(TokenType.STRING, "\"" + s + "\"", 0);
-    return new SimpleStringLiteral(token, s);
+    return astFactory.simpleStringLiteral(token, s);
   }
 
   static SimpleStringLiteral tripleQuotedStringLiteral(String s) {
     StringToken token = new StringToken(TokenType.STRING, '"""' + s + '"""', 0);
-    return new SimpleStringLiteral(token, s);
+    return astFactory.simpleStringLiteral(token, s);
   }
 
   static AsExpression asExpression(Expression exp, TypeName type) {
     Token token = new KeywordToken(Keyword.AS, 0);
-    return new AsExpression(exp, token, type);
+    return astFactory.asExpression(exp, token, type);
   }
 
   static IsExpression isExpression(Expression exp, TypeName type) {
     Token token = new KeywordToken(Keyword.IS, 0);
-    return new IsExpression(exp, token, null, type);
+    return astFactory.isExpression(exp, token, null, type);
   }
 
   static ParenthesizedExpression parenthesizedExpression(Expression exp) {
     Token lp = new BeginToken(TokenType.OPEN_PAREN, exp.offset);
     Token rp = new Token(TokenType.CLOSE_PAREN, exp.end);
-    return new ParenthesizedExpression(lp, exp, rp);
+    return astFactory.parenthesizedExpression(lp, exp, rp);
   }
 
   static BinaryExpression binaryExpression(
       Expression l, Token op, Expression r) {
-    return new BinaryExpression(l, op, r);
+    return astFactory.binaryExpression(l, op, r);
   }
 
   static ConditionalExpression conditionalExpression(
       Expression cond, Expression tExp, Expression fExp) {
     var q = new Token(TokenType.QUESTION, 0);
     var c = new Token(TokenType.COLON, 0);
-    return new ConditionalExpression(cond, q, tExp, c, fExp);
+    return astFactory.conditionalExpression(cond, q, tExp, c, fExp);
   }
 
   static Expression functionExpressionInvocation(
       Expression function, ArgumentList es) {
-    return new FunctionExpressionInvocation(function, null, es);
+    return astFactory.functionExpressionInvocation(function, null, es);
   }
 
   static FormalParameterList formalParameterList(List<FormalParameter> params) {
@@ -507,67 +509,67 @@
       ld = new BeginToken(TokenType.OPEN_CURLY_BRACKET, 0);
       rd = new Token(TokenType.CLOSE_CURLY_BRACKET, 0);
     }
-    return new FormalParameterList(lp, params, ld, rd, rp);
+    return astFactory.formalParameterList(lp, params, ld, rd, rp);
   }
 
   static Block block(List<Statement> statements) {
     Token ld = new BeginToken(TokenType.OPEN_CURLY_BRACKET, 0);
     Token rd = new Token(TokenType.CLOSE_CURLY_BRACKET, 0);
-    return new Block(ld, statements, rd);
+    return astFactory.block(ld, statements, rd);
   }
 
   static BlockFunctionBody blockFunctionBody(Block b) {
-    return new BlockFunctionBody(null, null, b);
+    return astFactory.blockFunctionBody(null, null, b);
   }
 
   static ExpressionFunctionBody expressionFunctionBody(Expression body,
       [bool decl = false]) {
     Token semi = (decl) ? new Token(TokenType.SEMICOLON, 0) : null;
-    return new ExpressionFunctionBody(null, null, body, semi);
+    return astFactory.expressionFunctionBody(null, null, body, semi);
   }
 
   static ExpressionStatement expressionStatement(Expression expression) {
     Token semi = new Token(TokenType.SEMICOLON, 0);
-    return new ExpressionStatement(expression, semi);
+    return astFactory.expressionStatement(expression, semi);
   }
 
   static FunctionDeclaration functionDeclaration(
       TypeName rt, SimpleIdentifier f, FunctionExpression fexp) {
-    return new FunctionDeclaration(null, null, null, rt, null, f, fexp);
+    return astFactory.functionDeclaration(null, null, null, rt, null, f, fexp);
   }
 
   static MethodDeclaration methodDeclaration(TypeName rt, SimpleIdentifier m,
       FormalParameterList fl, FunctionBody body,
       {bool isStatic: false}) {
     Token st = isStatic ? new KeywordToken(Keyword.STATIC, 0) : null;
-    return new MethodDeclaration(
+    return astFactory.methodDeclaration(
         null, null, null, st, rt, null, null, m, null, fl, body);
   }
 
   static FunctionExpression functionExpression(
       FormalParameterList fl, FunctionBody body) {
-    return new FunctionExpression(null, fl, body);
+    return astFactory.functionExpression(null, fl, body);
   }
 
   static FunctionDeclarationStatement functionDeclarationStatement(
       FunctionDeclaration fd) {
-    return new FunctionDeclarationStatement(fd);
+    return astFactory.functionDeclarationStatement(fd);
   }
 
   static Statement returnExpression([Expression e]) {
     Token ret = new KeywordToken(Keyword.RETURN, 0);
     Token semi = new Token(TokenType.SEMICOLON, 0);
-    return new ReturnStatement(ret, e, semi);
+    return astFactory.returnStatement(ret, e, semi);
   }
 
   static SimpleFormalParameter simpleFormalParameter(
       SimpleIdentifier v, TypeName t) {
-    return new SimpleFormalParameter(null, <Annotation>[], null, t, v);
+    return astFactory.simpleFormalParameter(null, <Annotation>[], null, t, v);
   }
 
   static FunctionTypedFormalParameter functionTypedFormalParameter(
       TypeName ret, SimpleIdentifier v, FormalParameterList ps) {
-    return new FunctionTypedFormalParameter(
+    return astFactory.functionTypedFormalParameter(
         null, <Annotation>[], ret, v, null, ps);
   }
 
@@ -576,11 +578,13 @@
   }
 
   static FormalParameter optionalFormalParameter(NormalFormalParameter fp) {
-    return new DefaultFormalParameter(fp, ParameterKind.POSITIONAL, null, null);
+    return astFactory.defaultFormalParameter(
+        fp, ParameterKind.POSITIONAL, null, null);
   }
 
   static FormalParameter namedFormalParameter(NormalFormalParameter fp) {
-    return new DefaultFormalParameter(fp, ParameterKind.NAMED, null, null);
+    return astFactory.defaultFormalParameter(
+        fp, ParameterKind.NAMED, null, null);
   }
 
   static NamedExpression namedParameter(SimpleIdentifier s, Expression e) {
@@ -588,13 +592,13 @@
   }
 
   static NamedExpression namedExpression(SimpleIdentifier s, Expression e) {
-    Label l = new Label(s, new Token(TokenType.COLON, 0));
-    return new NamedExpression(l, e);
+    Label l = astFactory.label(s, new Token(TokenType.COLON, 0));
+    return astFactory.namedExpression(l, e);
   }
 
   static VariableDeclarationStatement variableDeclarationStatement(
       VariableDeclarationList varDecl) {
     var semi = new Token(TokenType.SEMICOLON, 0);
-    return new VariableDeclarationStatement(varDecl, semi);
+    return astFactory.variableDeclarationStatement(varDecl, semi);
   }
 }
diff --git a/pkg/dev_compiler/lib/src/compiler/code_generator.dart b/pkg/dev_compiler/lib/src/compiler/code_generator.dart
index 1d36734..d973207 100644
--- a/pkg/dev_compiler/lib/src/compiler/code_generator.dart
+++ b/pkg/dev_compiler/lib/src/compiler/code_generator.dart
@@ -8,6 +8,7 @@
 
 import 'package:analyzer/analyzer.dart' hide ConstantEvaluator;
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart' show Token, TokenType;
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
@@ -1314,7 +1315,7 @@
       jsMethods.add(new JS.Method(
           _propertyName('constructor'),
           js.call('function(...args) { return this.new.apply(this, args); }')
-          as JS.Fun));
+              as JS.Fun));
     } else if (ctors.isEmpty) {
       jsMethods.add(_emitImplicitConstructor(node, fields, virtualFields));
     }
@@ -3971,7 +3972,7 @@
           new JS.Method(
               access,
               js.call('function() { return #; }', _visitInitializer(node))
-              as JS.Fun,
+                  as JS.Fun,
               isGetter: true),
           node,
           _findAccessor(element, getter: true)));
@@ -4457,8 +4458,8 @@
     //   LocalVariableElementImpl, so we could repurpose to mean "temp".
     // * add a new property to LocalVariableElementImpl.
     // * create a new subtype of LocalVariableElementImpl to mark a temp.
-    var id =
-        new SimpleIdentifier(new StringToken(TokenType.IDENTIFIER, name, -1));
+    var id = astFactory
+        .simpleIdentifier(new StringToken(TokenType.IDENTIFIER, name, -1));
 
     variable ??= new JS.TemporaryId(name);
 
@@ -4513,14 +4514,14 @@
     Expression result;
     if (expr is IndexExpression) {
       IndexExpression index = expr;
-      result = new IndexExpression.forTarget(
+      result = astFactory.indexExpressionForTarget(
           _bindValue(scope, 'o', index.target, context: context),
           index.leftBracket,
           _bindValue(scope, 'i', index.index, context: context),
           index.rightBracket);
     } else if (expr is PropertyAccess) {
       PropertyAccess prop = expr;
-      result = new PropertyAccess(
+      result = astFactory.propertyAccess(
           _bindValue(scope, 'o', _getTarget(prop), context: context),
           prop.operator,
           prop.propertyName);
@@ -4529,9 +4530,9 @@
       if (isLibraryPrefix(ident.prefix)) {
         return expr;
       }
-      result = new PrefixedIdentifier(
+      result = astFactory.prefixedIdentifier(
           _bindValue(scope, 'o', ident.prefix, context: context)
-          as SimpleIdentifier,
+              as SimpleIdentifier,
           ident.period,
           ident.identifier);
     } else {
diff --git a/pkg/dev_compiler/lib/src/compiler/reify_coercions.dart b/pkg/dev_compiler/lib/src/compiler/reify_coercions.dart
index c0a9f72..595d540 100644
--- a/pkg/dev_compiler/lib/src/compiler/reify_coercions.dart
+++ b/pkg/dev_compiler/lib/src/compiler/reify_coercions.dart
@@ -4,6 +4,7 @@
 
 import 'package:analyzer/analyzer.dart' as analyzer;
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/element/type.dart' show DartType;
 import 'package:analyzer/src/dart/ast/ast.dart' show FunctionBodyImpl;
 import 'package:analyzer/src/dart/ast/utilities.dart' show NodeReplacer;
@@ -40,7 +41,8 @@
   static Expression castExpression(Expression e, DartType toType) {
     // We use an empty name in the AST, because the JS code generator only cares
     // about the target type. It does not look at the AST name.
-    var typeName = new TypeName(AstBuilder.identifierFromString(''), null);
+    var typeName =
+        astFactory.typeName(AstBuilder.identifierFromString(''), null);
     typeName.type = toType;
     var cast = AstBuilder.asExpression(e, typeName);
     cast.staticType = toType;
diff --git a/pkg/dev_compiler/test/browser/language_tests.js b/pkg/dev_compiler/test/browser/language_tests.js
index 6cf5f8f..b0b2378 100644
--- a/pkg/dev_compiler/test/browser/language_tests.js
+++ b/pkg/dev_compiler/test/browser/language_tests.js
@@ -275,8 +275,6 @@
       'setter_no_getter_test_01_multi': skip_fail,
       'stack_overflow_stacktrace_test': skip_fail,
       'stack_overflow_test': skip_fail,
-      'stack_trace_test': skip_fail,
-      'stacktrace_rethrow_nonerror_test': skip_fail, // mismatch from Karma's file hash
       'stacktrace_rethrow_error_test_none_multi': skip_fail,
       'stacktrace_rethrow_error_test_withtraceparameter_multi': skip_fail,
       'stacktrace_test': skip_fail,
@@ -377,7 +375,6 @@
       'regress_r21715_test': fail,
       'throw_half_surrogate_pair_test_02_multi': fail,
       'splay_tree_from_iterable_test': firefox_fail,
-      'stacktrace_current_test': chrome_fail,
       'string_case_test_01_multi': firefox_fail,
       'string_fromcharcodes_test': skip_timeout,
       'string_operations_with_null_test': fail,
@@ -426,7 +423,7 @@
     'lib/html': {
       'async_spawnuri_test': async_unittest,
       'async_test': async_unittest,
-      'audiocontext_test': is.chrome('<=55') ? fail : pass, // was sdk#27578, needs triage
+      'audiocontext_test': is.chrome('<=54') ? fail : pass, // was sdk#27578, needs triage
       'blob_constructor_test': 'fail', // was sdk#27578, needs triage
       'canvas_test': ['unittest'],
       'canvasrenderingcontext2d_test': ['unittest'],
diff --git a/pkg/dev_compiler/tool/input_sdk/lib/async/stream_impl.dart b/pkg/dev_compiler/tool/input_sdk/lib/async/stream_impl.dart
index dffaa12..7099973 100644
--- a/pkg/dev_compiler/tool/input_sdk/lib/async/stream_impl.dart
+++ b/pkg/dev_compiler/tool/input_sdk/lib/async/stream_impl.dart
@@ -401,7 +401,7 @@
    * during the call, and it checks for state changes after the call
    * that should cause further callbacks.
    */
-  void _guardCallback(callback) {
+  void _guardCallback(void callback()) {
     assert(!_inCallback);
     bool wasInputPaused = _isInputPaused;
     _state |= _STATE_IN_CALLBACK;
diff --git a/pkg/dev_compiler/tool/input_sdk/patch/async_patch.dart b/pkg/dev_compiler/tool/input_sdk/patch/async_patch.dart
index dfc883a..b49a23b 100644
--- a/pkg/dev_compiler/tool/input_sdk/patch/async_patch.dart
+++ b/pkg/dev_compiler/tool/input_sdk/patch/async_patch.dart
@@ -16,6 +16,9 @@
 
 import 'dart:_foreign_helper' show JS;
 
+typedef void _Callback();
+typedef void _TakeCallback(_Callback callback);
+
 @patch
 class _AsyncRun {
   @patch
@@ -24,10 +27,10 @@
   }
 
   // Lazily initialized.
-  static final Function _scheduleImmediateClosure =
+  static final _TakeCallback _scheduleImmediateClosure =
       _initializeScheduleImmediate();
 
-  static Function _initializeScheduleImmediate() {
+  static _TakeCallback _initializeScheduleImmediate() {
     // TODO(rnystrom): Not needed by dev_compiler.
     // requiresPreamble();
     if (JS('', 'self.scheduleImmediate') != null) {
@@ -38,7 +41,7 @@
       // Use mutationObservers.
       var div = JS('', 'self.document.createElement("div")');
       var span = JS('', 'self.document.createElement("span")');
-      var storedCallback;
+      _Callback storedCallback;
 
       internalCallback(_) {
         leaveJsAsync();
diff --git a/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart b/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart
index 392abf0..0e3acaf 100644
--- a/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart
+++ b/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart
@@ -552,25 +552,20 @@
   if (!$condition) $throwAssertionError();
 })()''');
 
-final _stack = JS('', 'new WeakMap()');
+var _stack = null;
 @JSExportName('throw')
 throw_(obj) => JS(
     '',
     '''(() => {
-  if ($obj != null && (typeof $obj == 'object' || typeof $obj == 'function')) {
-    // TODO(jmesserly): couldn't we store the most recent stack in a single
-    // variable? There should only be one active stack trace. That would
-    // allow it to work for things like strings and numbers.
-    $_stack.set($obj, new Error());
-  }
-  throw $obj;
+    $_stack = new Error();
+    throw $obj;
 })()''');
 
 getError(exception) => JS(
     '',
     '''(() => {
-  var stack = $_stack.get($exception);
-  return stack !== void 0 ? stack : $exception;
+  var stack = $_stack;
+  return stack !== null ? stack : $exception;
 })()''');
 
 // This is a utility function: it is only intended to be called from dev
diff --git a/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/rtti.dart b/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/rtti.dart
index d97b6bd..344c592 100644
--- a/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/rtti.dart
+++ b/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/rtti.dart
@@ -183,7 +183,7 @@
 }
 
 /// Given a WrappedType, return the internal runtime type object.
-unwrapType(obj) => obj._wrappedType;
+unwrapType(WrappedType obj) => obj._wrappedType;
 
 _getRuntimeType(value) => JS('', '#[#]', value, _runtimeType);
 getIsNamedConstructor(value) => JS('', '#[#]', value, isNamedConstructor);
diff --git a/pkg/dev_compiler/tool/input_sdk/private/preambles/d8.js b/pkg/dev_compiler/tool/input_sdk/private/preambles/d8.js
index aed0161..c330ad8 100644
--- a/pkg/dev_compiler/tool/input_sdk/private/preambles/d8.js
+++ b/pkg/dev_compiler/tool/input_sdk/private/preambles/d8.js
@@ -33,7 +33,6 @@
   self.location = { href: "file://" + workingDirectory + "/" };
 
   // Event loop.
-
   // Task queue as cyclic list queue.
   var taskQueue = new Array(8);  // Length is power of 2.
   var head = 0;
@@ -77,7 +76,7 @@
   // That field is cleared when the timer is cancelled, but it is not returned
   // from the queue until its time comes.
   var timerIds = {};
-  var timerIdCounter = 1;  // Counter used to assing ids.
+  var timerIdCounter = 1;  // Counter used to assign ids.
 
   // Zero-timer queue as simple array queue using push/shift.
   var zeroTimerQueue = [];
diff --git a/pkg/dev_compiler/tool/sdk_expected_errors.txt b/pkg/dev_compiler/tool/sdk_expected_errors.txt
index 80eacbc..63ae0c6 100644
--- a/pkg/dev_compiler/tool/sdk_expected_errors.txt
+++ b/pkg/dev_compiler/tool/sdk_expected_errors.txt
@@ -1,5 +1,12 @@
 [error] Couldn't infer type parameter 'T'; '_ControllerEventSinkWrapper<dynamic>' must be of type 'EventSink<T>'. (dart:async/stream.dart, line 1346, col 16)
 [error] The argument type '_ControllerEventSinkWrapper' can't be assigned to the parameter type 'EventSink<T>'. (dart:async/stream.dart, line 1346, col 53)
+[error] A value of type '<R>(Zone, ZoneDelegate, Zone, () → R) → R' can't be assigned to a parameter of type '(Zone, ZoneDelegate, Zone, () → dynamic) → dynamic'. (dart:async/zone.dart, line 1071, col 51)
+[error] A value of type '<R,T>(Zone, ZoneDelegate, Zone, (T) → R, T) → R' can't be assigned to a parameter of type '(Zone, ZoneDelegate, Zone, (dynamic) → dynamic, dynamic) → dynamic'. (dart:async/zone.dart, line 1073, col 56)
+[error] A value of type '<R,T1,T2>(Zone, ZoneDelegate, Zone, (T1, T2) → R, T1, T2) → R' can't be assigned to a parameter of type '(Zone, ZoneDelegate, Zone, (dynamic, dynamic) → dynamic, dynamic, dynamic) → dynamic'. (dart:async/zone.dart, line 1075, col 57)
+[error] A value of type '<R>(Zone, ZoneDelegate, Zone, () → R) → () → R' can't be assigned to a parameter of type '(Zone, ZoneDelegate, Zone, () → dynamic) → () → dynamic'. (dart:async/zone.dart, line 1078, col 23)
+[error] A value of type '<R,T>(Zone, ZoneDelegate, Zone, (T) → R) → (T) → R' can't be assigned to a parameter of type '(Zone, ZoneDelegate, Zone, (dynamic) → dynamic) → (dynamic) → dynamic'. (dart:async/zone.dart, line 1081, col 23)
+[error] A value of type '<R,T1,T2>(Zone, ZoneDelegate, Zone, (T1, T2) → R) → (T1, T2) → R' can't be assigned to a parameter of type '(Zone, ZoneDelegate, Zone, (dynamic, dynamic) → dynamic) → (dynamic, dynamic) → dynamic'. (dart:async/zone.dart, line 1084, col 23)
+[error] A value of type '<R>(Zone, ZoneDelegate, Zone, dynamic, StackTrace) → R' can't be assigned to a parameter of type '(Zone, ZoneDelegate, Zone, dynamic, StackTrace) → dynamic'. (dart:async/zone.dart, line 1100, col 23)
 [error] Invalid override. The type of 'ChunkedConverter.bind' ('(dynamic) → dynamic') isn't a subtype of 'Converter<S, T>.bind' ('(Stream<S>) → Stream<T>'). (dart:convert/chunked_conversion.dart, line 14, col 3)
 [error] Invalid override. The type of 'ChunkedConverter.bind' ('(dynamic) → dynamic') isn't a subtype of 'StreamTransformer<S, T>.bind' ('(Stream<S>) → Stream<T>'). (dart:convert/chunked_conversion.dart, line 14, col 3)
 [error] Invalid override. The type of 'ChunkedConverter.startChunkedConversion' ('(dynamic) → dynamic') isn't a subtype of 'Converter<S, T>.startChunkedConversion' ('(Sink<T>) → Sink<S>'). (dart:convert/chunked_conversion.dart, line 15, col 3)
diff --git a/pkg/front_end/lib/compiler_options.dart b/pkg/front_end/lib/compiler_options.dart
index f9f2f29..ac75dd1 100644
--- a/pkg/front_end/lib/compiler_options.dart
+++ b/pkg/front_end/lib/compiler_options.dart
@@ -6,6 +6,7 @@
 
 import 'compilation_error.dart';
 import 'file_system.dart';
+import 'physical_file_system.dart';
 
 /// Callback used to report errors encountered during compilation.
 typedef void ErrorHandler(CompilationError error);
@@ -91,12 +92,9 @@
 
   /// The [FileSystem] which should be used by the front end to access files.
   ///
-  /// TODO(paulberry): once an implementation of [FileSystem] has been created
-  /// which uses the actual physical file system, make that the default.
-  ///
   /// All file system access performed by the front end goes through this
   /// mechanism, with one exception: if no value is specified for
   /// [packagesFilePath], the packages file is located using the actual physical
   /// file system.  TODO(paulberry): fix this.
-  FileSystem fileSystem;
+  FileSystem fileSystem = PhysicalFileSystem.instance;
 }
diff --git a/pkg/front_end/lib/kernel_generator.dart b/pkg/front_end/lib/kernel_generator.dart
index 3b35086..ce9eee8 100644
--- a/pkg/front_end/lib/kernel_generator.dart
+++ b/pkg/front_end/lib/kernel_generator.dart
@@ -5,9 +5,14 @@
 /// Defines the front-end API for converting source code to Dart Kernel objects.
 library front_end.kernel_generator;
 
-import 'dart:async';
+import 'compilation_error.dart';
 import 'compiler_options.dart';
-import 'package:kernel/kernel.dart' as kernel;
+import 'dart:async';
+
+// TODO(sigmund): move loader logic under front_end/lib/src/kernel/
+import 'package:kernel/analyzer/loader.dart';
+import 'package:kernel/kernel.dart';
+import 'package:source_span/source_span.dart' show SourceSpan;
 
 /// Generates a kernel representation of the program whose main library is in
 /// the given [source].
@@ -24,8 +29,12 @@
 ///
 /// TODO(paulberry): will the VM have a pickled version of the SDK inside it? If
 /// so, then maybe this method should not convert SDK libraries to kernel.
-Future<kernel.Program> kernelForProgram(Uri source, CompilerOptions options) =>
-    throw new UnimplementedError();
+Future<Program> kernelForProgram(Uri source, CompilerOptions options) async {
+  var loader = await _createLoader(options);
+  Program program = loader.loadProgram(source);
+  _reportErrors(loader.errors, options.onError);
+  return program;
+}
 
 /// Generates a kernel representation of the build unit whose source files are
 /// in [sources].
@@ -46,13 +55,51 @@
 /// are also listed in [sources], otherwise an error results.  (It is not
 /// permitted to refer to a part file declared in another build unit).
 ///
-/// The return value is a [kernel.Program] object with no main method set.
+/// The return value is a [Program] object with no main method set.
 /// TODO(paulberry): would it be better to define a data type in kernel to
 /// represent a bundle of all the libraries in a given build unit?
 ///
 /// TODO(paulberry): does additional information need to be output to allow the
 /// caller to match up referenced elements to the summary files they were
 /// obtained from?
-Future<kernel.Program> kernelForBuildUnit(
-        List<Uri> sources, CompilerOptions options) =>
-    throw new UnimplementedError();
+Future<Program> kernelForBuildUnit(
+        List<Uri> sources, CompilerOptions options) async {
+  var repository = new Repository();
+  var loader = await _createLoader(options, repository: repository);
+  // TODO(sigmund): add special handling for part files.
+  sources.forEach(loader.loadLibrary);
+  Program program = new Program(repository.libraries);
+  _reportErrors(loader.errors, options.onError);
+  return program;
+}
+
+Future<DartLoader> _createLoader(CompilerOptions options,
+    {Repository repository}) async {
+  var kernelOptions = _convertOptions(options);
+  var packages = await createPackages(options.packagesFilePath);
+  return new DartLoader(
+      repository ?? new Repository(), kernelOptions, packages);
+}
+
+DartOptions _convertOptions(CompilerOptions options) {
+  return new DartOptions(
+      sdk: options.sdkPath,
+      packagePath: options.packagesFilePath,
+      declaredVariables: options.declaredVariables);
+}
+
+void _reportErrors(List errors, ErrorHandler onError) {
+  if (onError == null) return;
+  for (var error in errors) {
+    onError(new _DartkError(error));
+  }
+}
+
+// TODO(sigmund): delete this class. Dartk should not format errors itself, we
+// should just pass them along.
+class _DartkError implements CompilationError {
+  String get correction => null;
+  SourceSpan get span => null;
+  final String message;
+  _DartkError(this.message);
+}
diff --git a/pkg/front_end/lib/src/async_dependency_walker.dart b/pkg/front_end/lib/src/async_dependency_walker.dart
new file mode 100644
index 0000000..b0c6535
--- /dev/null
+++ b/pkg/front_end/lib/src/async_dependency_walker.dart
@@ -0,0 +1,172 @@
+// 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.
+
+import 'dart:async';
+
+/**
+ * An instance of [AsyncDependencyWalker] contains the core algorithms for
+ * walking a dependency graph and evaluating nodes in a safe order.
+ *
+ * Computation of dependencies and evaluation of nodes may be asynchronous.
+ */
+abstract class AsyncDependencyWalker<NodeType extends Node<NodeType>> {
+  /**
+   * Called by [walk] to evaluate a single non-cyclical node, after
+   * all that node's dependencies have been evaluated.
+   */
+  Future<Null> evaluate(NodeType v);
+
+  /**
+   * Called by [walk] to evaluate a strongly connected component
+   * containing one or more nodes.  All dependencies of the strongly
+   * connected component have been evaluated.
+   */
+  Future<Null> evaluateScc(List<NodeType> scc);
+
+  /**
+   * Walk the dependency graph starting at [startingPoint], finding
+   * strongly connected components and evaluating them in a safe order
+   * by calling [evaluate] and [evaluateScc].
+   *
+   * This is an implementation of Tarjan's strongly connected
+   * components algorithm
+   * (https://en.wikipedia.org/wiki/Tarjan%27s_strongly_connected_components_algorithm).
+   *
+   * TODO(paulberry): Consider switching to an algorithm that allows
+   * dependencies to be computed in parallel, and nodes to be evaluated in
+   * parallel.
+   */
+  Future<Null> walk(NodeType startingPoint) async {
+    // TODO(paulberry): consider rewriting in a non-recursive way so
+    // that long dependency chains don't cause stack overflow.
+
+    // TODO(paulberry): in the event that an exception occurs during
+    // the walk, restore the state of the [Node] data structures so
+    // that further evaluation will be safe.
+
+    // The index which will be assigned to the next node that is
+    // freshly visited.
+    int index = 1;
+
+    // Stack of nodes which have been seen so far and whose strongly
+    // connected component is still being determined.  Nodes are only
+    // popped off the stack when they are evaluated, so sometimes the
+    // stack contains nodes that were visited after the current node.
+    List<NodeType> stack = <NodeType>[];
+
+    Future strongConnect(NodeType node) async {
+      bool hasTrivialCycle = false;
+
+      // Assign the current node an index and add it to the stack.  We
+      // haven't seen any of its dependencies yet, so set its lowLink
+      // to its index, indicating that so far it is the only node in
+      // its strongly connected component.
+      node._index = node._lowLink = index++;
+      stack.add(node);
+
+      // Consider the node's dependencies one at a time.
+      var dependencies =
+          node._dependencies ??= await node.computeDependencies();
+      for (NodeType dependency in dependencies) {
+        // If the dependency has already been evaluated, it can't be
+        // part of this node's strongly connected component, so we can
+        // skip it.
+        if (dependency._isEvaluated) {
+          continue;
+        }
+        if (identical(node, dependency)) {
+          // If a node includes itself as a dependency, there is no need to
+          // explore the dependency further.
+          hasTrivialCycle = true;
+        } else if (dependency._index == 0) {
+          // The dependency hasn't been seen yet, so recurse on it.
+          await strongConnect(dependency);
+          // If the dependency's lowLink refers to a node that was
+          // visited before the current node, that means that the
+          // current node, the dependency, and the node referred to by
+          // the dependency's lowLink are all part of the same
+          // strongly connected component, so we need to update the
+          // current node's lowLink accordingly.
+          if (dependency._lowLink < node._lowLink) {
+            node._lowLink = dependency._lowLink;
+          }
+        } else {
+          // The dependency has already been seen, so it is part of
+          // the current node's strongly connected component.  If it
+          // was visited earlier than the current node's lowLink, then
+          // it is a new addition to the current node's strongly
+          // connected component, so we need to update the current
+          // node's lowLink accordingly.
+          if (dependency._index < node._lowLink) {
+            node._lowLink = dependency._index;
+          }
+        }
+      }
+
+      // If the current node's lowLink is the same as its index, then
+      // we have finished visiting a strongly connected component, so
+      // pop the stack and evaluate it before moving on.
+      if (node._lowLink == node._index) {
+        // The strongly connected component has only one node.  If there is a
+        // cycle, it's a trivial one.
+        if (identical(stack.last, node)) {
+          stack.removeLast();
+          node._isEvaluated = true;
+          if (hasTrivialCycle) {
+            await evaluateScc(<NodeType>[node]);
+          } else {
+            await evaluate(node);
+          }
+        } else {
+          // There are multiple nodes in the strongly connected
+          // component.
+          List<NodeType> scc = <NodeType>[];
+          while (true) {
+            NodeType otherNode = stack.removeLast();
+            scc.add(otherNode);
+            otherNode._isEvaluated = true;
+            if (identical(otherNode, node)) {
+              break;
+            }
+          }
+          await evaluateScc(scc);
+        }
+      }
+    }
+
+    // Kick off the algorithm starting with the starting point.
+    await strongConnect(startingPoint);
+  }
+}
+
+/**
+ * Instances of [Node] represent nodes in a dependency graph.  The
+ * type parameter, [NodeType], is the derived type (this affords some
+ * extra type safety by making it difficult to accidentally construct
+ * bridges between unrelated dependency graphs).
+ */
+abstract class Node<NodeType> {
+  /**
+   * Index used by Tarjan's strongly connected components algorithm.
+   * Zero means the node has not been visited yet; a nonzero value
+   * counts the order in which the node was visited.
+   */
+  int _index = 0;
+
+  /**
+   * Low link used by Tarjan's strongly connected components
+   * algorithm.  This represents the smallest [_index] of all the nodes
+   * in the strongly connected component to which this node belongs.
+   */
+  int _lowLink = 0;
+
+  List<NodeType> _dependencies;
+
+  bool _isEvaluated = false;
+
+  /**
+   * Compute the dependencies of this node.
+   */
+  Future<List<NodeType>> computeDependencies();
+}
diff --git a/pkg/front_end/lib/src/dependency_walker.dart b/pkg/front_end/lib/src/dependency_walker.dart
new file mode 100644
index 0000000..7a27acb
--- /dev/null
+++ b/pkg/front_end/lib/src/dependency_walker.dart
@@ -0,0 +1,168 @@
+// 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.
+
+/**
+ * Instances of [Node] represent nodes in a dependency graph.  The
+ * type parameter, [NodeType], is the derived type (this affords some
+ * extra type safety by making it difficult to accidentally construct
+ * bridges between unrelated dependency graphs).
+ */
+abstract class Node<NodeType> {
+  /**
+   * Index used by Tarjan's strongly connected components algorithm.
+   * Zero means the node has not been visited yet; a nonzero value
+   * counts the order in which the node was visited.
+   */
+  int _index = 0;
+
+  /**
+   * Low link used by Tarjan's strongly connected components
+   * algorithm.  This represents the smallest [_index] of all the nodes
+   * in the strongly connected component to which this node belongs.
+   */
+  int _lowLink = 0;
+
+  List<NodeType> _dependencies;
+
+  /**
+   * Retrieve the dependencies of this node.
+   */
+  List<NodeType> get dependencies => _dependencies ??= computeDependencies();
+
+  /**
+   * Indicates whether this node has been evaluated yet.
+   */
+  bool get isEvaluated;
+
+  /**
+   * Compute the dependencies of this node.
+   */
+  List<NodeType> computeDependencies();
+}
+
+/**
+ * An instance of [DependencyWalker] contains the core algorithms for
+ * walking a dependency graph and evaluating nodes in a safe order.
+ */
+abstract class DependencyWalker<NodeType extends Node<NodeType>> {
+  /**
+   * Called by [walk] to evaluate a single non-cyclical node, after
+   * all that node's dependencies have been evaluated.
+   */
+  void evaluate(NodeType v);
+
+  /**
+   * Called by [walk] to evaluate a strongly connected component
+   * containing one or more nodes.  All dependencies of the strongly
+   * connected component have been evaluated.
+   */
+  void evaluateScc(List<NodeType> scc);
+
+  /**
+   * Walk the dependency graph starting at [startingPoint], finding
+   * strongly connected components and evaluating them in a safe order
+   * by calling [evaluate] and [evaluateScc].
+   *
+   * This is an implementation of Tarjan's strongly connected
+   * components algorithm
+   * (https://en.wikipedia.org/wiki/Tarjan%27s_strongly_connected_components_algorithm).
+   */
+  void walk(NodeType startingPoint) {
+    // TODO(paulberry): consider rewriting in a non-recursive way so
+    // that long dependency chains don't cause stack overflow.
+
+    // TODO(paulberry): in the event that an exception occurs during
+    // the walk, restore the state of the [Node] data structures so
+    // that further evaluation will be safe.
+
+    // The index which will be assigned to the next node that is
+    // freshly visited.
+    int index = 1;
+
+    // Stack of nodes which have been seen so far and whose strongly
+    // connected component is still being determined.  Nodes are only
+    // popped off the stack when they are evaluated, so sometimes the
+    // stack contains nodes that were visited after the current node.
+    List<NodeType> stack = <NodeType>[];
+
+    void strongConnect(NodeType node) {
+      bool hasTrivialCycle = false;
+
+      // Assign the current node an index and add it to the stack.  We
+      // haven't seen any of its dependencies yet, so set its lowLink
+      // to its index, indicating that so far it is the only node in
+      // its strongly connected component.
+      node._index = node._lowLink = index++;
+      stack.add(node);
+
+      // Consider the node's dependencies one at a time.
+      for (NodeType dependency in node.dependencies) {
+        // If the dependency has already been evaluated, it can't be
+        // part of this node's strongly connected component, so we can
+        // skip it.
+        if (dependency.isEvaluated) {
+          continue;
+        }
+        if (identical(node, dependency)) {
+          // If a node includes itself as a dependency, there is no need to
+          // explore the dependency further.
+          hasTrivialCycle = true;
+        } else if (dependency._index == 0) {
+          // The dependency hasn't been seen yet, so recurse on it.
+          strongConnect(dependency);
+          // If the dependency's lowLink refers to a node that was
+          // visited before the current node, that means that the
+          // current node, the dependency, and the node referred to by
+          // the dependency's lowLink are all part of the same
+          // strongly connected component, so we need to update the
+          // current node's lowLink accordingly.
+          if (dependency._lowLink < node._lowLink) {
+            node._lowLink = dependency._lowLink;
+          }
+        } else {
+          // The dependency has already been seen, so it is part of
+          // the current node's strongly connected component.  If it
+          // was visited earlier than the current node's lowLink, then
+          // it is a new addition to the current node's strongly
+          // connected component, so we need to update the current
+          // node's lowLink accordingly.
+          if (dependency._index < node._lowLink) {
+            node._lowLink = dependency._index;
+          }
+        }
+      }
+
+      // If the current node's lowLink is the same as its index, then
+      // we have finished visiting a strongly connected component, so
+      // pop the stack and evaluate it before moving on.
+      if (node._lowLink == node._index) {
+        // The strongly connected component has only one node.  If there is a
+        // cycle, it's a trivial one.
+        if (identical(stack.last, node)) {
+          stack.removeLast();
+          if (hasTrivialCycle) {
+            evaluateScc(<NodeType>[node]);
+          } else {
+            evaluate(node);
+          }
+        } else {
+          // There are multiple nodes in the strongly connected
+          // component.
+          List<NodeType> scc = <NodeType>[];
+          while (true) {
+            NodeType otherNode = stack.removeLast();
+            scc.add(otherNode);
+            if (identical(otherNode, node)) {
+              break;
+            }
+          }
+          evaluateScc(scc);
+        }
+      }
+    }
+
+    // Kick off the algorithm starting with the starting point.
+    strongConnect(startingPoint);
+  }
+}
diff --git a/pkg/front_end/test/src/async_dependency_walker_test.dart b/pkg/front_end/test/src/async_dependency_walker_test.dart
new file mode 100644
index 0000000..8cf0b28
--- /dev/null
+++ b/pkg/front_end/test/src/async_dependency_walker_test.dart
@@ -0,0 +1,220 @@
+// 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.
+
+import 'dart:async';
+
+import 'package:front_end/src/async_dependency_walker.dart';
+import 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(AsyncDependencyWalkerTest);
+  });
+}
+
+@reflectiveTest
+class AsyncDependencyWalkerTest {
+  final nodes = <String, TestNode>{};
+
+  Future<Null> checkGraph(
+      Map<String, List<String>> graph,
+      String startingNodeName,
+      List<List<String>> expectedEvaluations,
+      List<bool> expectedSccFlags) async {
+    makeGraph(graph);
+    var walker = await walk(startingNodeName);
+    expect(walker._evaluations, expectedEvaluations.map((x) => x.toSet()));
+    expect(walker._sccFlags, expectedSccFlags);
+  }
+
+  TestNode getNode(String name) =>
+      nodes.putIfAbsent(name, () => new TestNode(name));
+
+  void makeGraph(Map<String, List<String>> graph) {
+    graph.forEach((name, deps) {
+      var node = getNode(name);
+      for (var dep in deps) {
+        node._dependencies.add(getNode(dep));
+      }
+    });
+  }
+
+  test_complex_graph() async {
+    await checkGraph(
+        {
+          'a': ['b', 'c'],
+          'b': ['c', 'd'],
+          'c': [],
+          'd': ['c', 'e'],
+          'e': ['b', 'f'],
+          'f': ['c', 'd']
+        },
+        'a',
+        [
+          ['c'],
+          ['b', 'd', 'e', 'f'],
+          ['a']
+        ],
+        [false, true, false]);
+  }
+
+  test_diamond() async {
+    await checkGraph(
+        {
+          'a': ['b', 'c'],
+          'b': ['d'],
+          'c': ['d'],
+          'd': []
+        },
+        'a',
+        [
+          ['d'],
+          ['b'],
+          ['c'],
+          ['a']
+        ],
+        [false, false, false, false]);
+  }
+
+  test_singleNode() async {
+    await checkGraph(
+        {'a': []},
+        'a',
+        [
+          ['a']
+        ],
+        [false]);
+  }
+
+  test_singleNodeWithTrivialCycle() async {
+    await checkGraph(
+        {
+          'a': ['a']
+        },
+        'a',
+        [
+          ['a']
+        ],
+        [true]);
+  }
+
+  test_threeNodesWithCircularDependency() async {
+    await checkGraph(
+        {
+          'a': ['b'],
+          'b': ['c'],
+          'c': ['a'],
+        },
+        'a',
+        [
+          ['a', 'b', 'c']
+        ],
+        [true]);
+  }
+
+  test_twoBacklinksEarlierFirst() async {
+    // Test a graph A->B->C->D, where D points back to B and then C.
+    await checkGraph(
+        {
+          'a': ['b'],
+          'b': ['c'],
+          'c': ['d'],
+          'd': ['b', 'c']
+        },
+        'a',
+        [
+          ['b', 'c', 'd'],
+          ['a']
+        ],
+        [true, false]);
+  }
+
+  test_twoBacklinksLaterFirst() async {
+    // Test a graph A->B->C->D, where D points back to C and then B.
+    await checkGraph(
+        {
+          'a': ['b'],
+          'b': ['c'],
+          'c': ['d'],
+          'd': ['c', 'b']
+        },
+        'a',
+        [
+          ['b', 'c', 'd'],
+          ['a']
+        ],
+        [true, false]);
+  }
+
+  test_twoNodesWithCircularDependency() async {
+    await checkGraph(
+        {
+          'a': ['b'],
+          'b': ['a']
+        },
+        'a',
+        [
+          ['a', 'b']
+        ],
+        [true]);
+  }
+
+  test_twoNodesWithSimpleDependency() async {
+    await checkGraph(
+        {
+          'a': ['b'],
+          'b': []
+        },
+        'a',
+        [
+          ['b'],
+          ['a']
+        ],
+        [false, false]);
+  }
+
+  Future<TestWalker> walk(String startingNodeName) async {
+    var testWalker = new TestWalker();
+    await testWalker.walk(getNode(startingNodeName));
+    return testWalker;
+  }
+}
+
+class TestNode extends Node<TestNode> {
+  final String _name;
+
+  bool _computeDependenciesCalled = false;
+
+  final _dependencies = <TestNode>[];
+
+  TestNode(this._name);
+
+  @override
+  Future<List<TestNode>> computeDependencies() async {
+    expect(_computeDependenciesCalled, false);
+    _computeDependenciesCalled = true;
+    return _dependencies;
+  }
+}
+
+class TestWalker extends AsyncDependencyWalker<TestNode> {
+  final _evaluations = <Set<String>>[];
+  final _sccFlags = <bool>[];
+
+  @override
+  Future<Null> evaluate(TestNode v) async {
+    _evaluations.add([v._name].toSet());
+    _sccFlags.add(false);
+  }
+
+  @override
+  Future<Null> evaluateScc(List<TestNode> scc) async {
+    var sccNames = scc.map((node) => node._name).toSet();
+    // Make sure there were no duplicates
+    expect(sccNames.length, scc.length);
+    _evaluations.add(sccNames);
+    _sccFlags.add(true);
+  }
+}
diff --git a/pkg/front_end/test/src/dependency_walker_test.dart b/pkg/front_end/test/src/dependency_walker_test.dart
new file mode 100644
index 0000000..d4c731b
--- /dev/null
+++ b/pkg/front_end/test/src/dependency_walker_test.dart
@@ -0,0 +1,219 @@
+// 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.
+
+import 'package:front_end/src/dependency_walker.dart';
+import 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(DependencyWalkerTest);
+  });
+}
+
+@reflectiveTest
+class DependencyWalkerTest {
+  final nodes = <String, TestNode>{};
+
+  void checkGraph(Map<String, List<String>> graph, String startingNodeName,
+      List<List<String>> expectedEvaluations, List<bool> expectedSccFlags) {
+    makeGraph(graph);
+    var walker = walk(startingNodeName);
+    expect(walker._evaluations, expectedEvaluations.map((x) => x.toSet()));
+    expect(walker._sccFlags, expectedSccFlags);
+  }
+
+  TestNode getNode(String name) =>
+      nodes.putIfAbsent(name, () => new TestNode(name));
+
+  void makeGraph(Map<String, List<String>> graph) {
+    graph.forEach((name, deps) {
+      var node = getNode(name);
+      for (var dep in deps) {
+        node._dependencies.add(getNode(dep));
+      }
+    });
+  }
+
+  void test_complex_graph() {
+    checkGraph(
+        {
+          'a': ['b', 'c'],
+          'b': ['c', 'd'],
+          'c': [],
+          'd': ['c', 'e'],
+          'e': ['b', 'f'],
+          'f': ['c', 'd']
+        },
+        'a',
+        [
+          ['c'],
+          ['b', 'd', 'e', 'f'],
+          ['a']
+        ],
+        [false, true, false]);
+  }
+
+  void test_diamond() {
+    checkGraph(
+        {
+          'a': ['b', 'c'],
+          'b': ['d'],
+          'c': ['d'],
+          'd': []
+        },
+        'a',
+        [
+          ['d'],
+          ['b'],
+          ['c'],
+          ['a']
+        ],
+        [false, false, false, false]);
+  }
+
+  void test_singleNode() {
+    checkGraph(
+        {'a': []},
+        'a',
+        [
+          ['a']
+        ],
+        [false]);
+  }
+
+  void test_singleNodeWithTrivialCycle() {
+    checkGraph(
+        {
+          'a': ['a']
+        },
+        'a',
+        [
+          ['a']
+        ],
+        [true]);
+  }
+
+  void test_threeNodesWithCircularDependency() {
+    checkGraph(
+        {
+          'a': ['b'],
+          'b': ['c'],
+          'c': ['a'],
+        },
+        'a',
+        [
+          ['a', 'b', 'c']
+        ],
+        [true]);
+  }
+
+  test_twoBacklinksEarlierFirst() {
+    // Test a graph A->B->C->D, where D points back to B and then C.
+    checkGraph(
+        {
+          'a': ['b'],
+          'b': ['c'],
+          'c': ['d'],
+          'd': ['b', 'c']
+        },
+        'a',
+        [
+          ['b', 'c', 'd'],
+          ['a']
+        ],
+        [true, false]);
+  }
+
+  test_twoBacklinksLaterFirst() {
+    // Test a graph A->B->C->D, where D points back to C and then B.
+    checkGraph(
+        {
+          'a': ['b'],
+          'b': ['c'],
+          'c': ['d'],
+          'd': ['c', 'b']
+        },
+        'a',
+        [
+          ['b', 'c', 'd'],
+          ['a']
+        ],
+        [true, false]);
+  }
+
+  void test_twoNodesWithCircularDependency() {
+    checkGraph(
+        {
+          'a': ['b'],
+          'b': ['a']
+        },
+        'a',
+        [
+          ['a', 'b']
+        ],
+        [true]);
+  }
+
+  void test_twoNodesWithSimpleDependency() {
+    checkGraph(
+        {
+          'a': ['b'],
+          'b': []
+        },
+        'a',
+        [
+          ['b'],
+          ['a']
+        ],
+        [false, false]);
+  }
+
+  TestWalker walk(String startingNodeName) =>
+      new TestWalker()..walk(getNode(startingNodeName));
+}
+
+class TestNode extends Node<TestNode> {
+  final String _name;
+
+  @override
+  bool isEvaluated = false;
+
+  bool _computeDependenciesCalled = false;
+
+  final _dependencies = <TestNode>[];
+
+  TestNode(this._name);
+
+  @override
+  List<TestNode> computeDependencies() {
+    expect(_computeDependenciesCalled, false);
+    _computeDependenciesCalled = true;
+    return _dependencies;
+  }
+}
+
+class TestWalker extends DependencyWalker<TestNode> {
+  final _evaluations = <Set<String>>[];
+  final _sccFlags = <bool>[];
+
+  @override
+  void evaluate(TestNode v) {
+    v.isEvaluated = true;
+    _evaluations.add([v._name].toSet());
+    _sccFlags.add(false);
+  }
+
+  @override
+  void evaluateScc(List<TestNode> scc) {
+    for (var v in scc) {
+      v.isEvaluated = true;
+    }
+    var sccNames = scc.map((node) => node._name).toSet();
+    // Make sure there were no duplicates
+    expect(sccNames.length, scc.length);
+    _evaluations.add(sccNames);
+    _sccFlags.add(true);
+  }
+}
diff --git a/pkg/front_end/tool/example.dart b/pkg/front_end/tool/example.dart
new file mode 100644
index 0000000..1d49b22
--- /dev/null
+++ b/pkg/front_end/tool/example.dart
@@ -0,0 +1,27 @@
+import 'dart:async';
+
+import 'package:front_end/kernel_generator.dart';
+import 'package:front_end/compiler_options.dart';
+import 'package:kernel/binary/ast_to_binary.dart';
+import 'package:kernel/kernel.dart' show Program;
+
+Future dumpToSink(Program program, StreamSink<List<int>> sink) {
+  new BinaryPrinter(sink).writeProgramFile(program);
+  return sink.close();
+}
+
+Future kernelToSink(Uri entry, StreamSink<List<int>> sink) async {
+  var program = await kernelForProgram(entry,
+      new CompilerOptions()
+        ..sdkPath = 'sdk'
+        ..packagesFilePath = '.packages'
+        ..onError = (e) => print(e.message));
+
+  await dumpToSink(program, sink);
+}
+
+main(args) async {
+  kernelToSink(Uri.base.resolve(args[0]),
+      // TODO(sigmund,hausner): define memory type where to dump binary data.
+      new StreamController<List<int>>.broadcast().sink);
+}
diff --git a/pkg/front_end/tool/perf.dart b/pkg/front_end/tool/perf.dart
index 4d61e9b..4fa76ed 100644
--- a/pkg/front_end/tool/perf.dart
+++ b/pkg/front_end/tool/perf.dart
@@ -19,6 +19,10 @@
 import 'package:analyzer/src/generated/parser.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:analyzer/src/generated/source_io.dart';
+import 'package:analyzer/src/summary/format.dart';
+import 'package:analyzer/src/summary/idl.dart';
+import 'package:analyzer/src/summary/prelink.dart';
+import 'package:analyzer/src/summary/summarize_ast.dart';
 import 'package:kernel/analyzer/loader.dart';
 import 'package:kernel/kernel.dart';
 import 'package:package_config/discovery.dart';
@@ -33,6 +37,12 @@
 /// Cumulative time spent scanning.
 Stopwatch scanTimer = new Stopwatch();
 
+/// Cumulative time spent parsing.
+Stopwatch parseTimer = new Stopwatch();
+
+/// Cumulative time spent building unlinked summaries.
+Stopwatch unlinkedSummarizeTimer = new Stopwatch();
+
 /// Factory to load and resolve app, packages, and sdk sources.
 SourceFactory sources;
 
@@ -69,6 +79,16 @@
       // are leaking memory?). That's why we run it twice and not 10 times.
       for (int i = 0; i < 2; i++) await generateKernel(entryUri);
     },
+    'unlinked_summarize': () async {
+      Set<Source> files = scanReachableFiles(entryUri);
+      // TODO(sigmund): replace the warmup with instrumented snapshots.
+      for (int i = 0; i < 10; i++) unlinkedSummarizeFiles(files);
+    },
+    'prelinked_summarize': () async {
+      Set<Source> files = scanReachableFiles(entryUri);
+      // TODO(sigmund): replace the warmup with instrumented snapshots.
+      for (int i = 0; i < 10; i++) prelinkedSummarizeFiles(files);
+    }
   };
 
   var handler = handlers[bench];
@@ -159,18 +179,87 @@
   scanTimer = new Stopwatch();
   var old = scanTotalChars;
   scanTotalChars = 0;
-  var parseTimer = new Stopwatch()..start();
+  parseTimer = new Stopwatch();
   for (var source in files) {
     parseFull(source);
   }
-  parseTimer.stop();
 
   // Report size and scanning time again. See discussion above.
   if (old != scanTotalChars) print('input size changed? ${old} chars');
   report("scan", scanTimer.elapsedMicroseconds);
+  report("parse", parseTimer.elapsedMicroseconds);
+}
 
-  var pTime = parseTimer.elapsedMicroseconds - scanTimer.elapsedMicroseconds;
-  report("parse", pTime);
+/// Produces unlinked summaries for every file in [files] and reports the time
+/// spent doing so.
+void unlinkedSummarizeFiles(Set<Source> files) {
+  // The code below will record again how many chars are scanned and how long it
+  // takes to scan them, even though we already did so in [scanReachableFiles].
+  // Recording and reporting this twice is unnecessary, but we do so for now to
+  // validate that the results are consistent.
+  scanTimer = new Stopwatch();
+  var old = scanTotalChars;
+  scanTotalChars = 0;
+  parseTimer = new Stopwatch();
+  unlinkedSummarizeTimer = new Stopwatch();
+  for (var source in files) {
+    unlinkedSummarize(source);
+  }
+
+  if (old != scanTotalChars) print('input size changed? ${old} chars');
+  report("scan", scanTimer.elapsedMicroseconds);
+  report("parse", parseTimer.elapsedMicroseconds);
+  report('unlinked summarize', unlinkedSummarizeTimer.elapsedMicroseconds);
+  report(
+      'unlinked summarize + parse',
+      unlinkedSummarizeTimer.elapsedMicroseconds +
+          parseTimer.elapsedMicroseconds);
+}
+
+/// Produces prelinked summaries for every file in [files] and reports the time
+/// spent doing so.
+void prelinkedSummarizeFiles(Set<Source> files) {
+  // The code below will record again how many chars are scanned and how long it
+  // takes to scan them, even though we already did so in [scanReachableFiles].
+  // Recording and reporting this twice is unnecessary, but we do so for now to
+  // validate that the results are consistent.
+  scanTimer = new Stopwatch();
+  var old = scanTotalChars;
+  scanTotalChars = 0;
+  parseTimer = new Stopwatch();
+  unlinkedSummarizeTimer = new Stopwatch();
+  var unlinkedSummaries = <Source, UnlinkedUnit>{};
+  for (var source in files) {
+    unlinkedSummaries[source] = unlinkedSummarize(source);
+  }
+  var prelinkTimer = new Stopwatch()..start();
+  for (var source in files) {
+    UnlinkedUnit getSummary(String uri) {
+      var resolvedUri = sources.resolveUri(source, uri);
+      var result = unlinkedSummaries[resolvedUri];
+      if (result == null) {
+        print('Warning: no summary found for: $uri');
+      }
+      return result;
+    }
+
+    UnlinkedPublicNamespace getImport(String uri) =>
+        getSummary(uri)?.publicNamespace;
+    String getDeclaredVariable(String s) => null;
+    prelink(
+        unlinkedSummaries[source], getSummary, getImport, getDeclaredVariable);
+  }
+  prelinkTimer.stop();
+
+  if (old != scanTotalChars) print('input size changed? ${old} chars');
+  report("scan", scanTimer.elapsedMicroseconds);
+  report("parse", parseTimer.elapsedMicroseconds);
+  report('unlinked summarize', unlinkedSummarizeTimer.elapsedMicroseconds);
+  report(
+      'unlinked summarize + parse',
+      unlinkedSummarizeTimer.elapsedMicroseconds +
+          parseTimer.elapsedMicroseconds);
+  report('prelink', prelinkTimer.elapsedMicroseconds);
 }
 
 /// Add to [files] all sources reachable from [start].
@@ -195,8 +284,19 @@
 /// Parse the full body of [source] and return it's compilation unit.
 CompilationUnit parseFull(Source source) {
   var token = tokenize(source);
+  parseTimer.start();
   var parser = new Parser(source, AnalysisErrorListener.NULL_LISTENER);
-  return parser.parseCompilationUnit(token);
+  var unit = parser.parseCompilationUnit(token);
+  parseTimer.stop();
+  return unit;
+}
+
+UnlinkedUnitBuilder unlinkedSummarize(Source source) {
+  var unit = parseFull(source);
+  unlinkedSummarizeTimer.start();
+  var unlinkedUnit = serializeAstUnlinked(unit);
+  unlinkedSummarizeTimer.stop();
+  return unlinkedUnit;
 }
 
 /// Scan [source] and return the first token produced by the scanner.
@@ -241,7 +341,7 @@
   var repository = new Repository();
   DartLoader loader = new DartLoader(repository, options, packages);
 
-  Program program = loader.loadProgram(entryUri.path);
+  Program program = loader.loadProgram(entryUri);
   List errors = loader.errors;
   if (errors.isNotEmpty) {
     const int errorLimit = 100;
diff --git a/pkg/kernel/bin/dartk.dart b/pkg/kernel/bin/dartk.dart
index e735f97..f6a6447 100755
--- a/pkg/kernel/bin/dartk.dart
+++ b/pkg/kernel/bin/dartk.dart
@@ -10,6 +10,7 @@
 
 import 'package:args/args.dart';
 import 'package:kernel/analyzer/loader.dart';
+import 'package:kernel/application_root.dart';
 import 'package:kernel/verifier.dart';
 import 'package:kernel/kernel.dart';
 import 'package:kernel/log.dart';
@@ -36,6 +37,11 @@
   ..addOption('packages',
       abbr: 'p', help: 'Path to the .packages file or packages folder.')
   ..addOption('package-root', help: 'Deprecated alias for --packages')
+  ..addOption('app-root',
+      help: 'Store library paths relative to the given directory.\n'
+          'If none is given, absolute paths are used.\n'
+          'Application libraries not inside the application root are stored '
+          'using absolute paths')
   ..addOption('target',
       abbr: 't',
       help: 'Tailor the IR to the given target.',
@@ -244,6 +250,13 @@
   String packagePath = options['packages'] ?? options['package-root'];
   checkIsFileOrDirectoryOrNull(packagePath, 'Package root or .packages');
 
+  String applicationRootOption = options['app-root'];
+  checkIsDirectoryOrNull(applicationRootOption, 'Application root');
+  if (applicationRootOption != null) {
+    applicationRootOption = new File(applicationRootOption).absolute.path;
+  }
+  var applicationRoot = new ApplicationRoot(applicationRootOption);
+
   // Set up logging.
   if (options['verbose']) {
     log.onRecord.listen((LogRecord rec) {
@@ -255,9 +268,10 @@
     return fail('Exactly one FILE should be given.');
   }
 
-  var file = options.rest.single;
-
+  String file = options.rest.single;
   checkIsFile(file, option: 'Input file');
+  file = new File(file).absolute.path;
+  Uri fileUri = new Uri(scheme: 'file', path: file);
 
   String format = options['format'] ?? defaultFormat();
   String outputFile = options['out'] ?? defaultOutput();
@@ -297,16 +311,18 @@
         sdk: options['sdk'],
         packagePath: packagePath,
         customUriMappings: customUriMappings,
-        declaredVariables: declaredVariables);
+        declaredVariables: declaredVariables,
+        applicationRoot: applicationRoot);
     String packageDiscoveryPath = batchModeState.isBatchMode ? null : file;
     DartLoader loader = await batchModeState.batch.getLoader(
         repository, dartOptions,
         packageDiscoveryPath: packageDiscoveryPath);
     if (options['link']) {
-      program = loader.loadProgram(file, target: target);
+      program = loader.loadProgram(fileUri, target: target);
     } else {
-      var library = loader.loadLibrary(file);
-      assert(library == repository.getLibrary(file));
+      var library = loader.loadLibrary(fileUri);
+      assert(library ==
+          repository.getLibraryReference(applicationRoot.relativeUri(fileUri)));
       program = new Program(repository.libraries);
     }
     errors = loader.errors;
diff --git a/pkg/kernel/binary.md b/pkg/kernel/binary.md
index 6f8a03a..71b7f33 100644
--- a/pkg/kernel/binary.md
+++ b/pkg/kernel/binary.md
@@ -42,45 +42,43 @@
 
 type MagicWord = big endian 32-bit unsigned integer
 
-type String {
-  UInt num_bytes;
-  Byte[num_bytes] utf8_bytes;
-}
-
-type StringTable {
-  UInt num_strings;
-  String[num_strings] strings;
-}
-
-type StringReference {
-  UInt index; // Index into the StringTable.
-}
-
-type LineStarts {
-  UInt lineCount;
-  // Delta encoded, e.g. 0, 10, 15, 7, 10 means 0, 10, 25, 32, 42.
-  UInt[lineCount] lineStarts;
-}
-
-type UriLineStarts {
-  StringTable uris;
-  LineStarts[uris.num_strings] lineStarts;
-}
-
-type UriReference {
-  UInt index; // Index into the URIs StringTable.
-}
-
-type FileOffset {
-  // Saved as number+1 to accommodate literal "-1".
-  UInt fileOffset;
-}
-
 type List<T> {
   UInt length;
   T[length] items;
 }
 
+type String {
+  List<Byte> utf8Bytes;
+}
+
+type StringTable {
+  List<String> strings;
+}
+
+type StringReference {
+  UInt index; // Index into the StringTable strings.
+}
+
+type LineStarts {
+  // Line starts are delta-encoded (they are encoded as line lengths).  The list
+  // [0, 10, 25, 32, 42] is encoded as [0, 10, 15, 7, 10].
+  List<Uint> lineStarts;
+}
+
+type UriLineStarts {
+  List<String> uris;
+  LineStarts[uris.length] lineStarts;
+}
+
+type UriReference {
+  UInt index; // Index into the UriLineStarts uris.
+}
+
+type FileOffset {
+  // Encoded as offset + 1 to accommodate -1 indicating no offset.
+  UInt fileOffset;
+}
+
 type Option<T> {
   Byte tag;
 }
@@ -96,13 +94,12 @@
   MagicWord magic = 0x90ABCDEF;
   StringTable strings;
   UriLineStarts lineStartsMap;
-  List<Library> library;
+  List<Library> libraries;
   LibraryProcedureReference mainMethod;
 }
 
 type LibraryReference {
-  // For library files, this is an index into the import table.
-  // For program files, this is an index into the list of libaries.
+  // Index into the ProgramFile libraries.
   UInt index;
 }
 
@@ -169,8 +166,11 @@
 type Library {
   Byte flags (isExternal);
   StringReference name;
-  // A URI with the dart, package, or file scheme.  For file URIs, the path
-  // is an absolute path to the .dart file from which the library was created.
+  // A URI from which the library was created.  The URI has the dart, package,
+  // file, or app scheme.  For file URIs, the path is an absolute path to the
+  // .dart file from which the library was created.  For app URIs, the path is
+  // relative to an application root that was specified when the binary was
+  // generated.
   StringReference importUri;
   // An absolute path URI to the .dart file from which the library was created.
   UriReference fileUri;
diff --git a/pkg/kernel/lib/analyzer/ast_from_analyzer.dart b/pkg/kernel/lib/analyzer/ast_from_analyzer.dart
index 9847b59..caece79 100644
--- a/pkg/kernel/lib/analyzer/ast_from_analyzer.dart
+++ b/pkg/kernel/lib/analyzer/ast_from_analyzer.dart
@@ -1677,6 +1677,15 @@
     return element;
   }
 
+  /// Forces the list of type arguments to have the specified length. If the
+  /// length was changed, all type arguments are changed to `dynamic`.
+  void _coerceTypeArgumentArity(List<ast.DartType> typeArguments, int arity) {
+    if (typeArguments.length != arity) {
+      typeArguments.length = arity;
+      typeArguments.fillRange(0, arity, const ast.DynamicType());
+    }
+  }
+
   ast.Expression visitInstanceCreationExpression(
       InstanceCreationExpression node) {
     ConstructorElement element = node.staticElement;
@@ -1729,6 +1738,8 @@
     if (classElement.isEnum) {
       return scope.emitCompileTimeError(CompileTimeErrorCode.INSTANTIATE_ENUM);
     }
+    _coerceTypeArgumentArity(
+        arguments.types, classElement.typeParameters.length);
     if (element.isFactory) {
       ast.Member target = scope.resolveConcreteMethod(element);
       if (target is ast.Procedure &&
diff --git a/pkg/kernel/lib/analyzer/loader.dart b/pkg/kernel/lib/analyzer/loader.dart
index 1591bcf..ae16926 100644
--- a/pkg/kernel/lib/analyzer/loader.dart
+++ b/pkg/kernel/lib/analyzer/loader.dart
@@ -16,6 +16,7 @@
 import 'package:analyzer/src/generated/parser.dart';
 import 'package:analyzer/src/generated/sdk.dart';
 import 'package:analyzer/src/generated/source_io.dart';
+import 'package:kernel/application_root.dart';
 import 'package:package_config/discovery.dart';
 import 'package:package_config/packages.dart';
 
@@ -35,6 +36,7 @@
   bool strongModeSdk;
   String sdk;
   String packagePath;
+  ApplicationRoot applicationRoot;
   Map<Uri, Uri> customUriMappings;
   Map<String, String> declaredVariables;
 
@@ -43,12 +45,14 @@
       bool strongModeSdk,
       this.sdk,
       this.packagePath,
+      ApplicationRoot applicationRoot,
       Map<Uri, Uri> customUriMappings,
       Map<String, String> declaredVariables})
       : this.customUriMappings = customUriMappings ?? <Uri, Uri>{},
         this.declaredVariables = declaredVariables ?? <String, String>{},
         this.strongMode = strongMode,
-        this.strongModeSdk = strongModeSdk ?? strongMode;
+        this.strongModeSdk = strongModeSdk ?? strongMode,
+        this.applicationRoot = applicationRoot ?? new ApplicationRoot.none();
 }
 
 abstract class ReferenceLevelLoader {
@@ -68,6 +72,7 @@
 
 class DartLoader implements ReferenceLevelLoader {
   final Repository repository;
+  final ApplicationRoot applicationRoot;
   final Bimap<ClassElement, ast.Class> _classes =
       new Bimap<ClassElement, ast.Class>();
   final Bimap<Element, ast.Member> _members = new Bimap<Element, ast.Member>();
@@ -90,25 +95,22 @@
 
   DartLoader(this.repository, DartOptions options, Packages packages,
       {DartSdk dartSdk})
-      : this.context = createContext(options, packages, dartSdk: dartSdk);
-
-  LibraryElement getLibraryElement(ast.Library node) {
-    return context
-        .getLibraryElement(context.sourceFactory.forUri2(node.importUri));
-  }
+      : this.context = createContext(options, packages, dartSdk: dartSdk),
+        this.applicationRoot = options.applicationRoot;
 
   String getLibraryName(LibraryElement element) {
     return element.name.isEmpty ? null : element.name;
   }
 
   ast.Library getLibraryReference(LibraryElement element) {
-    return repository.getLibraryReference(element.source.uri)
+    var uri = applicationRoot.relativeUri(element.source.uri);
+    return repository.getLibraryReference(uri)
       ..name ??= getLibraryName(element)
       ..fileUri = "file://${element.source.fullName}";
   }
 
-  void _buildTopLevelMember(ast.Member member, Element element) {
-    var astNode = element.computeNode();
+  void _buildTopLevelMember(
+      ast.Member member, Element element, Declaration astNode) {
     assert(member.parent != null);
     new MemberBodyBuilder(this, member, element).build(astNode);
   }
@@ -122,45 +124,56 @@
     return _libraryBeingLoaded == element;
   }
 
-  void _buildLibraryBody(LibraryElement element, ast.Library library) {
+  void _buildLibraryBody(LibraryElement element, ast.Library library,
+      List<CompilationUnit> units) {
     assert(_libraryBeingLoaded == null);
     _libraryBeingLoaded = element;
     var classes = <ast.Class>[];
     var procedures = <ast.Procedure>[];
     var fields = <ast.Field>[];
-    void loadClass(ClassElement classElement) {
-      var node = getClassReference(classElement);
-      promoteToBodyLevel(node);
+
+    void loadClass(NamedCompilationUnitMember declaration) {
+      // [declaration] can be a ClassDeclaration, EnumDeclaration, or a
+      // ClassTypeAlias.
+      ClassElement element = declaration.element;
+      var node = getClassReference(element);
+      promoteToBodyLevel(node, element, declaration);
       classes.add(node);
     }
 
-    void loadProcedure(Element memberElement) {
-      var node = getMemberReference(memberElement);
-      _buildTopLevelMember(node, memberElement);
+    void loadProcedure(FunctionDeclaration declaration) {
+      var element = declaration.element;
+      var node = getMemberReference(element);
+      _buildTopLevelMember(node, element, declaration);
       procedures.add(node);
     }
 
-    void loadField(Element memberElement) {
-      var node = getMemberReference(memberElement);
-      _buildTopLevelMember(node, memberElement);
-      fields.add(node);
+    void loadField(TopLevelVariableDeclaration declaration) {
+      for (var field in declaration.variables.variables) {
+        var element = field.element;
+        // Ignore fields inserted through error recovery.
+        if (element.name == '') continue;
+        var node = getMemberReference(element);
+        _buildTopLevelMember(node, element, field);
+        fields.add(node);
+      }
     }
 
-    for (var unit in element.units) {
-      unit.types.forEach(loadClass);
-      unit.enums.forEach(loadClass);
-      for (var accessor in unit.accessors) {
-        if (!accessor.isSynthetic) {
-          loadProcedure(accessor);
-        }
-      }
-      for (var function in unit.functions) {
-        loadProcedure(function);
-      }
-      for (var field in unit.topLevelVariables) {
-        // Ignore fields inserted through error recovery.
-        if (!field.isSynthetic && field.name != '') {
-          loadField(field);
+    for (var unit in units) {
+      for (CompilationUnitMember declaration in unit.declarations) {
+        if (declaration is ClassDeclaration ||
+            declaration is EnumDeclaration ||
+            declaration is ClassTypeAlias) {
+          loadClass(declaration);
+        } else if (declaration is FunctionDeclaration) {
+          loadProcedure(declaration);
+        } else if (declaration is TopLevelVariableDeclaration) {
+          loadField(declaration);
+        } else if (declaration is FunctionTypeAlias) {
+          // Nothing to do. Typedefs are handled lazily while constructing type
+          // references.
+        } else {
+          throw "unexpected node: ${declaration.runtimeType} $declaration";
         }
       }
     }
@@ -350,13 +363,11 @@
     }
   }
 
-  void promoteToBodyLevel(ast.Class classNode) {
+  void promoteToBodyLevel(ast.Class classNode, ClassElement element,
+      NamedCompilationUnitMember astNode) {
     if (classNode.level == ast.ClassLevel.Body) return;
     promoteToHierarchyLevel(classNode);
     classNode.level = ast.ClassLevel.Body;
-    var element = getClassElement(classNode);
-    if (element == null) return;
-    var astNode = element.computeNode();
     // Clear out the member references that were put in the class.
     // The AST builder will load them all put back in the right order.
     classNode..fields.clear()..procedures.clear()..constructors.clear();
@@ -579,23 +590,32 @@
   void ensureLibraryIsLoaded(ast.Library node) {
     if (!node.isExternal) return;
     node.isExternal = false;
-    var source = context.sourceFactory.forUri2(node.importUri);
+    var source = context.sourceFactory
+        .forUri2(applicationRoot.absoluteUri(node.importUri));
     assert(source != null);
     var element = context.computeLibraryElement(source);
-    context.resolveCompilationUnit(source, element);
-    _buildLibraryBody(element, node);
-    if (node.importUri.scheme != 'dart') {
-      for (var unit in element.units) {
-        LineInfo lines;
-        for (var error in context.computeErrors(unit.source)) {
-          if (error.errorCode is CompileTimeErrorCode ||
-              error.errorCode is ParserErrorCode ||
-              error.errorCode is ScannerErrorCode ||
-              error.errorCode is StrongModeCode) {
-            lines ??= context.computeLineInfo(source);
-            errors.add(formatErrorMessage(error, source.shortName, lines));
-          }
-        }
+    var units = <CompilationUnit>[];
+    bool reportErrors = node.importUri.scheme != 'dart';
+    var tree = context.resolveCompilationUnit(source, element);
+    units.add(tree);
+    if (reportErrors) _processErrors(source);
+    for (var part in element.parts) {
+      var source = part.source;
+      units.add(context.resolveCompilationUnit(source, element));
+      if (reportErrors) _processErrors(source);
+    }
+    _buildLibraryBody(element, node, units);
+  }
+
+  void _processErrors(Source source) {
+    LineInfo lines;
+    for (var error in context.computeErrors(source)) {
+      if (error.errorCode is CompileTimeErrorCode ||
+          error.errorCode is ParserErrorCode ||
+          error.errorCode is ScannerErrorCode ||
+          error.errorCode is StrongModeCode) {
+        lines ??= context.computeLineInfo(source);
+        errors.add(formatErrorMessage(error, source.shortName, lines));
       }
     }
   }
@@ -623,8 +643,9 @@
   List<String> getLoadedFileNames() {
     var list = <String>[];
     for (var library in repository.libraries) {
-      LibraryElement element = context.computeLibraryElement(
-          context.sourceFactory.forUri2(library.importUri));
+      LibraryElement element = context.computeLibraryElement(context
+          .sourceFactory
+          .forUri2(applicationRoot.absoluteUri(library.importUri)));
       for (var unit in element.units) {
         list.add(unit.source.fullName);
       }
@@ -639,8 +660,9 @@
     }
   }
 
-  ast.Program loadProgram(String mainLibrary, {Target target}) {
-    ast.Library library = repository.getLibrary(mainLibrary);
+  ast.Program loadProgram(Uri mainLibrary, {Target target}) {
+    ast.Library library = repository
+        .getLibraryReference(applicationRoot.relativeUri(mainLibrary));
     ensureLibraryIsLoaded(library);
     loadEverything(target: target);
     var program = new ast.Program(repository.libraries);
@@ -650,10 +672,9 @@
     for (LibraryElement libraryElement in libraryElements) {
       for (CompilationUnitElement compilationUnitElement
           in libraryElement.units) {
-        // TODO(jensj): Get this another way?
-        LineInfo lineInfo = compilationUnitElement.computeNode().lineInfo;
-        program.uriToLineStarts[
-                "file://${compilationUnitElement.source.source.fullName}"] =
+        var source = compilationUnitElement.source;
+        LineInfo lineInfo = context.computeLineInfo(source);
+        program.uriToLineStarts["file://${source.fullName}"] =
             new List<int>.generate(lineInfo.lineCount, lineInfo.getOffsetOfLine,
                 growable: false);
       }
@@ -661,8 +682,9 @@
     return program;
   }
 
-  ast.Library loadLibrary(String mainLibrary) {
-    ast.Library library = repository.getLibrary(mainLibrary);
+  ast.Library loadLibrary(Uri uri) {
+    ast.Library library =
+        repository.getLibraryReference(applicationRoot.relativeUri(uri));
     ensureLibraryIsLoaded(library);
     return library;
   }
diff --git a/pkg/kernel/lib/application_root.dart b/pkg/kernel/lib/application_root.dart
new file mode 100644
index 0000000..a65d8dd
--- /dev/null
+++ b/pkg/kernel/lib/application_root.dart
@@ -0,0 +1,45 @@
+// 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.
+library kernel.application_root;
+
+import 'package:path/path.dart' as pathlib;
+
+/// Resolves URIs with the `app` scheme.
+///
+/// These are used internally in kernel to represent file paths relative to
+/// some application root. This is done to avoid storing irrelevant paths, such
+/// as the path to the home directory of the user who compiled a given file.
+class ApplicationRoot {
+  static const String scheme = 'app';
+
+  final String path;
+
+  ApplicationRoot(this.path) {
+    assert(path == null || pathlib.isAbsolute(path));
+  }
+
+  ApplicationRoot.none() : path = null;
+
+  /// Converts `app` URIs to absolute `file` URIs.
+  Uri absoluteUri(Uri uri) {
+    if (path == null) return uri;
+    if (uri.scheme == ApplicationRoot.scheme) {
+      return new Uri(scheme: 'file', path: pathlib.join(this.path, uri.path));
+    } else {
+      return uri;
+    }
+  }
+
+  /// Converts `file` URIs to `app` URIs.
+  Uri relativeUri(Uri uri) {
+    if (path == null) return uri;
+    if (uri.scheme == 'file' && pathlib.isWithin(this.path, uri.path)) {
+      return new Uri(
+          scheme: ApplicationRoot.scheme,
+          path: pathlib.relative(uri.path, from: this.path));
+    } else {
+      return uri;
+    }
+  }
+}
diff --git a/pkg/kernel/lib/ast.dart b/pkg/kernel/lib/ast.dart
index 0cece08..4093dd3 100644
--- a/pkg/kernel/lib/ast.dart
+++ b/pkg/kernel/lib/ast.dart
@@ -157,9 +157,11 @@
 // ------------------------------------------------------------------------
 
 class Library extends TreeNode implements Comparable<Library> {
-  /// An absolute import path to this library.
+  /// An import path to this library.
   ///
-  /// The [Uri] should have the `dart`, `package`, or `file` scheme.
+  /// The [Uri] should have the `dart`, `package`, `app`, or `file` scheme.
+  ///
+  /// If the URI has the `app` scheme, it is relative to the application root.
   Uri importUri;
 
   /// The uri of the source file this library was loaded from.
diff --git a/pkg/kernel/lib/class_hierarchy.dart b/pkg/kernel/lib/class_hierarchy.dart
index 32bf6958..17a981d 100644
--- a/pkg/kernel/lib/class_hierarchy.dart
+++ b/pkg/kernel/lib/class_hierarchy.dart
@@ -415,10 +415,14 @@
     }
     // One of the two lists is now exhausted, copy over the remains.
     while (i < declared.length) {
-      result[storeIndex++] = declared[i++];
+      Member declaredMember = declared[i++];
+      if (skipAbstractMembers && declaredMember.isAbstract) continue;
+      result[storeIndex++] = declaredMember;
     }
     while (j < inherited.length) {
-      result[storeIndex++] = inherited[j++];
+      Member inheritedMember = inherited[j++];
+      if (skipAbstractMembers && inheritedMember.isAbstract) continue;
+      result[storeIndex++] = inheritedMember;
     }
     result.length = storeIndex;
     return result;
diff --git a/pkg/kernel/lib/repository.dart b/pkg/kernel/lib/repository.dart
index 7689d90..265a75c 100644
--- a/pkg/kernel/lib/repository.dart
+++ b/pkg/kernel/lib/repository.dart
@@ -3,10 +3,6 @@
 // BSD-style license that can be found in the LICENSE file.
 library kernel.repository;
 
-import 'dart:io';
-
-import 'package:path/path.dart' as pathlib;
-
 import 'ast.dart';
 
 /// Keeps track of which [Library] objects have been created for a given URI.
@@ -14,61 +10,16 @@
 /// To load different files into the same IR, pass in the same repository
 /// object to the loaders.
 class Repository {
-  final String workingDirectory;
   final Map<Uri, Library> _uriToLibrary = <Uri, Library>{};
   final List<Library> libraries = <Library>[];
 
-  Repository({String workingDirectory})
-      : this.workingDirectory = workingDirectory ?? Directory.current.path;
-
-  /// Get the [Library] object for the library addresesd by [path]; possibly
-  /// as an external library.
-  ///
-  /// The [path] may be a relative or absolute file path, or a URI string with a
-  /// `dart:`, `package:` or `file:` scheme.
-  ///
-  /// Note that this method does not check if the library can be loaded at all.
-  Library getLibrary(String path) {
-    return getLibraryReference(normalizePath(path));
-  }
-
-  String normalizeFileExtension(String path) {
-    if (path.endsWith('.dill')) {
-      return path.substring(0, path.length - '.dill'.length) + '.dart';
-    } else {
-      return path;
-    }
-  }
-
-  /// Get the canonical URI for the library addressed by the given [path].
-  ///
-  /// The [path] may be a relative or absolute file path, or a URI string with a
-  /// `dart:`, `package:` or `file:` scheme.
-  Uri normalizePath(String path) {
-    var uri = Uri.parse(path);
-    if (!uri.hasScheme) {
-      if (!pathlib.isAbsolute(path)) {
-        path = pathlib.join(workingDirectory, path);
-      }
-      uri = new Uri(scheme: 'file', path: normalizeFileExtension(path));
-    } else if (uri.scheme == 'file') {
-      var path = normalizeFileExtension(uri.path);
-      if (!uri.hasAbsolutePath) {
-        uri = uri.replace(path: pathlib.join(workingDirectory, path));
-      } else {
-        uri = uri.replace(path: path);
-      }
-    }
-    return uri;
-  }
-
   Library getLibraryReference(Uri uri) {
     assert(uri.hasScheme);
-    assert(uri.scheme != 'file' || uri.hasAbsolutePath);
     return _uriToLibrary.putIfAbsent(uri, () => _buildLibraryReference(uri));
   }
 
   Library _buildLibraryReference(Uri uri) {
+    assert(uri.hasScheme);
     var library = new Library(uri, isExternal: true);
     libraries.add(library);
     return library;
diff --git a/pkg/kernel/lib/transformations/continuation.dart b/pkg/kernel/lib/transformations/continuation.dart
index fd6e1d2..97ef172 100644
--- a/pkg/kernel/lib/transformations/continuation.dart
+++ b/pkg/kernel/lib/transformations/continuation.dart
@@ -528,7 +528,8 @@
       var iteratorVariable = new VariableDeclaration(':for-iterator',
           initializer: new ConstructorInvocation(
               helper.streamIteratorConstructor,
-              new Arguments(<Expression>[stmt.iterable])));
+              new Arguments(<Expression>[stmt.iterable],
+                  types: [const DynamicType()])));
 
       // await iterator.moveNext()
       var condition = new AwaitExpression(new MethodInvocation(
@@ -733,8 +734,8 @@
 
     // var :completer = new Completer.sync();
     completerVariable = new VariableDeclaration(":completer",
-        initializer: new StaticInvocation(
-            helper.completerConstructor, new Arguments([])),
+        initializer: new StaticInvocation(helper.completerConstructor,
+            new Arguments([], types: [const DynamicType()])),
         isFinal: true);
     statements.add(completerVariable);
 
@@ -746,7 +747,8 @@
     // new Future.microtask(:async_op);
     var newMicrotaskStatement = new ExpressionStatement(new StaticInvocation(
         helper.futureMicrotaskConstructor,
-        new Arguments([new VariableGet(nestedClosureVariable)])));
+        new Arguments([new VariableGet(nestedClosureVariable)],
+            types: [const DynamicType()])));
     statements.add(newMicrotaskStatement);
 
     // return :completer.future;
diff --git a/pkg/kernel/lib/transformations/mixin_full_resolution.dart b/pkg/kernel/lib/transformations/mixin_full_resolution.dart
index 7669b1a..1cd1160 100644
--- a/pkg/kernel/lib/transformations/mixin_full_resolution.dart
+++ b/pkg/kernel/lib/transformations/mixin_full_resolution.dart
@@ -311,7 +311,8 @@
     return new StaticInvocation(
         _listFrom,
         new Arguments([new ListLiteral(list)],
-            named: [new NamedExpression("growable", new BoolLiteral(false))]));
+            named: [new NamedExpression("growable", new BoolLiteral(false))],
+            types: [const DynamicType()]));
   }
 
   /// Check that a call to the targetFunction is legal given the arguments.
diff --git a/pkg/kernel/lib/verifier.dart b/pkg/kernel/lib/verifier.dart
index e40b2c0..bed5417 100644
--- a/pkg/kernel/lib/verifier.dart
+++ b/pkg/kernel/lib/verifier.dart
@@ -246,6 +246,147 @@
   }
 
   @override
+  visitStaticGet(StaticGet node) {
+    visitChildren(node);
+    if (node.target == null) {
+      throw 'StaticGet without target found in $context.';
+    }
+    if (!node.target.hasGetter) {
+      throw 'StaticGet to ${node.target} without getter found in $context';
+    }
+    if (node.target.isInstanceMember) {
+      throw 'StaticGet to ${node.target} that is not static found in $context';
+    }
+  }
+
+  @override
+  visitStaticSet(StaticSet node) {
+    visitChildren(node);
+    if (node.target == null) {
+      throw 'StaticSet without target found in $context.';
+    }
+    if (!node.target.hasSetter) {
+      throw 'StaticSet to ${node.target} without setter found in $context';
+    }
+    if (node.target.isInstanceMember) {
+      throw 'StaticSet to ${node.target} that is not static found in $context';
+    }
+  }
+
+  @override
+  visitStaticInvocation(StaticInvocation node) {
+    visitChildren(node);
+    if (node.target == null) {
+      throw 'StaticInvocation without target found in $context.';
+    }
+    if (node.target.isInstanceMember) {
+      throw 'StaticInvocation to ${node.target} that is not static found in '
+          '$context';
+    }
+    if (!areArgumentsCompatible(node.arguments, node.target.function)) {
+      throw 'StaticInvocation with incompatible arguments to '
+          '${node.target} found in $context';
+    }
+    if (node.arguments.types.length !=
+        node.target.function.typeParameters.length) {
+      throw 'Wrong number of type arguments provided in StaticInvocation '
+          'to ${node.target} found in $context';
+    }
+  }
+
+  @override
+  visitDirectPropertyGet(DirectPropertyGet node) {
+    visitChildren(node);
+    if (node.target == null) {
+      throw 'DirectPropertyGet without target found in $context.';
+    }
+    if (!node.target.hasGetter) {
+      throw 'DirectPropertyGet to ${node.target} without getter found in '
+          '$context';
+    }
+    if (!node.target.isInstanceMember) {
+      throw 'DirectPropertyGet to ${node.target} that is static found in '
+          '$context';
+    }
+  }
+
+  @override
+  visitDirectPropertySet(DirectPropertySet node) {
+    visitChildren(node);
+    if (node.target == null) {
+      throw 'DirectPropertySet without target found in $context.';
+    }
+    if (!node.target.hasSetter) {
+      throw 'DirectPropertyGet to ${node.target} without setter found in '
+          '$context';
+    }
+    if (!node.target.isInstanceMember) {
+      throw 'DirectPropertySet to ${node.target} that is static found in '
+          '$context';
+    }
+  }
+
+  @override
+  visitDirectMethodInvocation(DirectMethodInvocation node) {
+    visitChildren(node);
+    if (node.target == null) {
+      throw 'DirectMethodInvocation without target found in $context.';
+    }
+    if (!node.target.isInstanceMember) {
+      throw 'DirectMethodInvocation to ${node.target} that is static found in '
+          '$context';
+    }
+    if (!areArgumentsCompatible(node.arguments, node.target.function)) {
+      throw 'DirectMethodInvocation with incompatible arguments to '
+          '${node.target} found in $context';
+    }
+    if (node.arguments.types.length !=
+        node.target.function.typeParameters.length) {
+      throw 'Wrong number of type arguments provided in DirectMethodInvocation '
+          'to ${node.target} found in $context';
+    }
+  }
+
+  @override
+  visitConstructorInvocation(ConstructorInvocation node) {
+    visitChildren(node);
+    if (node.target == null) {
+      throw 'ConstructorInvocation without target found in $context.';
+    }
+    if (node.target.enclosingClass.isAbstract) {
+      throw 'ConstructorInvocation to abstract class found in $context';
+    }
+    if (!areArgumentsCompatible(node.arguments, node.target.function)) {
+      throw 'ConstructorInvocation with incompatible arguments to '
+          '${node.target} found in $context';
+    }
+    if (node.arguments.types.length !=
+        node.target.enclosingClass.typeParameters.length) {
+      throw 'Wrong number of type arguments provided in ConstructorInvocation '
+          'to ${node.target} found in $context';
+    }
+  }
+
+  bool areArgumentsCompatible(Arguments arguments, FunctionNode function) {
+    if (arguments.positional.length < function.requiredParameterCount) {
+      return false;
+    }
+    if (arguments.positional.length > function.positionalParameters.length) {
+      return false;
+    }
+    namedLoop:
+    for (int i = 0; i < arguments.named.length; ++i) {
+      var argument = arguments.named[i];
+      String name = argument.name;
+      for (int j = 0; j < function.namedParameters.length; ++j) {
+        if (function.namedParameters[j].name == name) continue namedLoop;
+      }
+      return false;
+    }
+    return true;
+  }
+
+  @override
   defaultMemberReference(Member node) {
     if (node.transformerFlags & TransformerFlag.seenByVerifier == 0) {
       throw 'Dangling reference to $node found in $context.\n'
diff --git a/pkg/kernel/test/baseline_spec_mode_test_disabled.dart b/pkg/kernel/test/baseline_spec_mode_test.dart
similarity index 100%
rename from pkg/kernel/test/baseline_spec_mode_test_disabled.dart
rename to pkg/kernel/test/baseline_spec_mode_test.dart
diff --git a/pkg/kernel/test/baseline_strong_mode_test_disabled.dart b/pkg/kernel/test/baseline_strong_mode_test.dart
similarity index 100%
rename from pkg/kernel/test/baseline_strong_mode_test_disabled.dart
rename to pkg/kernel/test/baseline_strong_mode_test.dart
diff --git a/pkg/kernel/test/baseline_tester.dart b/pkg/kernel/test/baseline_tester.dart
index c2c47e5..b954e20 100644
--- a/pkg/kernel/test/baseline_tester.dart
+++ b/pkg/kernel/test/baseline_tester.dart
@@ -4,6 +4,7 @@
 import 'dart:io';
 
 import 'package:kernel/analyzer/loader.dart';
+import 'package:kernel/application_root.dart';
 import 'package:kernel/kernel.dart';
 import 'package:kernel/target/targets.dart';
 import 'package:kernel/text/ast_to_text.dart';
@@ -30,11 +31,13 @@
   String outputDirectory = '$testcaseDirectory/$folderName';
   var batch = new DartLoaderBatch();
   Directory directory = new Directory(inputDirectory);
+  var applicationRoot = new ApplicationRoot(directory.absolute.path);
   for (FileSystemEntity file in directory.listSync()) {
     if (file is File && file.path.endsWith('.dart')) {
       String name = pathlib.basename(file.path);
       test(name, () async {
-        String dartPath = file.path;
+        Uri dartPath =
+            new Uri(scheme: 'file', path: pathlib.absolute(file.path));
         String shortName = pathlib.withoutExtension(name);
         String filenameOfBaseline = '$outputDirectory/$shortName.baseline.txt';
         String filenameOfCurrent = '$outputDirectory/$shortName.current.txt';
@@ -45,7 +48,8 @@
             new DartOptions(
                 strongMode: target.strongMode,
                 sdk: sdkDirectory,
-                declaredVariables: target.extraDeclaredVariables));
+                declaredVariables: target.extraDeclaredVariables,
+                applicationRoot: applicationRoot));
         var program = loader.loadProgram(dartPath, target: target);
         verifyProgram(program);
         var errors = target.transformProgram(program);
diff --git a/pkg/kernel/test/baseline_type_propagation_test_disabled.dart b/pkg/kernel/test/baseline_type_propagation_test.dart
similarity index 100%
rename from pkg/kernel/test/baseline_type_propagation_test_disabled.dart
rename to pkg/kernel/test/baseline_type_propagation_test.dart
diff --git a/pkg/kernel/test/frontend_bench.dart b/pkg/kernel/test/frontend_bench.dart
index 796d064..9ca6abc 100644
--- a/pkg/kernel/test/frontend_bench.dart
+++ b/pkg/kernel/test/frontend_bench.dart
@@ -45,6 +45,7 @@
   bool strongMode = options['strong'];
 
   String path = options.rest.single;
+  var uri = new Uri(scheme: 'file', path: new File(path).absolute.path);
   var packages =
       getPackagesDirectory(new Uri(scheme: 'file', path: packagePath));
   Repository repository = new Repository();
@@ -54,7 +55,7 @@
           new DartOptions(
               strongMode: strongMode, sdk: sdk, packagePath: packagePath),
           packages)
-      .loadProgram(path);
+      .loadProgram(uri);
 
   CacheEntry.recomputedCounts.forEach((key, value) {
     print('Recomputed $key $value times');
diff --git a/pkg/kernel/test/type_hashcode_test_disabled.dart b/pkg/kernel/test/type_hashcode_test.dart
similarity index 94%
rename from pkg/kernel/test/type_hashcode_test_disabled.dart
rename to pkg/kernel/test/type_hashcode_test.dart
index aa7f2d4..468deb6 100644
--- a/pkg/kernel/test/type_hashcode_test_disabled.dart
+++ b/pkg/kernel/test/type_hashcode_test.dart
@@ -3,7 +3,7 @@
 // BSD-style license that can be found in the LICENSE file.
 import 'package:kernel/kernel.dart';
 import 'type_parser.dart';
-import 'type_unification_test_disabled.dart' show testCases;
+import 'type_unification_test.dart' show testCases;
 import 'package:test/test.dart';
 
 void checkHashCodeEquality(DartType type1, DartType type2) {
diff --git a/pkg/kernel/test/type_substitute_bounds_test_disabled.dart b/pkg/kernel/test/type_substitute_bounds_test.dart
similarity index 100%
rename from pkg/kernel/test/type_substitute_bounds_test_disabled.dart
rename to pkg/kernel/test/type_substitute_bounds_test.dart
diff --git a/pkg/kernel/test/type_substitution_identity_test_disabled.dart b/pkg/kernel/test/type_substitution_identity_test.dart
similarity index 93%
rename from pkg/kernel/test/type_substitution_identity_test_disabled.dart
rename to pkg/kernel/test/type_substitution_identity_test.dart
index 2e6c263..d07da2a 100644
--- a/pkg/kernel/test/type_substitution_identity_test_disabled.dart
+++ b/pkg/kernel/test/type_substitution_identity_test.dart
@@ -4,7 +4,7 @@
 import 'package:kernel/kernel.dart';
 import 'package:kernel/type_algebra.dart';
 import 'type_parser.dart';
-import 'type_unification_test_disabled.dart' show testCases;
+import 'type_unification_test.dart' show testCases;
 import 'package:test/test.dart';
 
 checkType(DartType type) {
diff --git a/pkg/kernel/test/type_subtype_test_disabled.dart b/pkg/kernel/test/type_subtype_test.dart
similarity index 100%
rename from pkg/kernel/test/type_subtype_test_disabled.dart
rename to pkg/kernel/test/type_subtype_test.dart
diff --git a/pkg/kernel/test/type_unification_test_disabled.dart b/pkg/kernel/test/type_unification_test.dart
similarity index 100%
rename from pkg/kernel/test/type_unification_test_disabled.dart
rename to pkg/kernel/test/type_unification_test.dart
diff --git a/pkg/kernel/test/uint31_pair_map_test_disabled.dart b/pkg/kernel/test/uint31_pair_map_test.dart
similarity index 100%
rename from pkg/kernel/test/uint31_pair_map_test_disabled.dart
rename to pkg/kernel/test/uint31_pair_map_test.dart
diff --git a/pkg/kernel/test/verify_test.dart b/pkg/kernel/test/verify_test.dart
index e9f03b9..11f54f9 100644
--- a/pkg/kernel/test/verify_test.dart
+++ b/pkg/kernel/test/verify_test.dart
@@ -125,6 +125,86 @@
     procedure.function = new FunctionNode(new EmptyStatement());
     return procedure;
   });
+  negativeTest('StaticGet without target', () {
+    return new StaticGet(null);
+  });
+  negativeTest('StaticSet without target', () {
+    return new StaticSet(null, new NullLiteral());
+  });
+  negativeTest('StaticInvocation without target', () {
+    return new StaticInvocation(null, new Arguments.empty());
+  });
+  positiveTest('Correct StaticInvocation', () {
+    var method = new Procedure(new Name('test'), ProcedureKind.Method, null,
+        isStatic: true);
+    method.function = new FunctionNode(
+        new ReturnStatement(
+            new StaticInvocation(method, new Arguments([new NullLiteral()]))),
+        positionalParameters: [new VariableDeclaration('p')])..parent = method;
+    return new Class(
+        name: 'Test',
+        supertype: objectClass.asRawSupertype,
+        procedures: [method]);
+  });
+  negativeTest('StaticInvocation with too many parameters', () {
+    var method = new Procedure(new Name('test'), ProcedureKind.Method, null,
+        isStatic: true);
+    method.function = new FunctionNode(new ReturnStatement(
+        new StaticInvocation(method, new Arguments([new NullLiteral()]))))
+      ..parent = method;
+    return new Class(
+        name: 'Test',
+        supertype: objectClass.asRawSupertype,
+        procedures: [method]);
+  });
+  negativeTest('StaticInvocation with too few parameters', () {
+    var method = new Procedure(new Name('test'), ProcedureKind.Method, null,
+        isStatic: true);
+    method.function = new FunctionNode(
+        new ReturnStatement(
+            new StaticInvocation(method, new Arguments.empty())),
+        positionalParameters: [new VariableDeclaration('p')])..parent = method;
+    return new Class(
+        name: 'Test',
+        supertype: objectClass.asRawSupertype,
+        procedures: [method]);
+  });
+  negativeTest('StaticInvocation with unmatched named parameter', () {
+    var method = new Procedure(new Name('test'), ProcedureKind.Method, null,
+        isStatic: true);
+    method.function = new FunctionNode(new ReturnStatement(new StaticInvocation(
+        method,
+        new Arguments([],
+            named: [new NamedExpression('p', new NullLiteral())]))))
+      ..parent = method;
+    return new Class(
+        name: 'Test',
+        supertype: objectClass.asRawSupertype,
+        procedures: [method]);
+  });
+  negativeTest('StaticInvocation with missing type argument', () {
+    var method = new Procedure(new Name('test'), ProcedureKind.Method, null,
+        isStatic: true);
+    method.function = new FunctionNode(
+        new ReturnStatement(
+            new StaticInvocation(method, new Arguments.empty())),
+        typeParameters: [makeTypeParameter()])..parent = method;
+    return new Class(
+        name: 'Test',
+        supertype: objectClass.asRawSupertype,
+        procedures: [method]);
+  });
+  negativeTest('ConstructorInvocation with missing type argument', () {
+    var constructor = new Constructor(null);
+    constructor.function = new FunctionNode(new ReturnStatement(
+        new ConstructorInvocation(constructor, new Arguments.empty())))
+      ..parent = constructor;
+    return new Class(
+        name: 'Test',
+        typeParameters: [makeTypeParameter()],
+        supertype: objectClass.asRawSupertype,
+        constructors: [constructor]);
+  });
 }
 
 checkHasError(Program program) {
diff --git a/pkg/kernel/testcases/strong-mode/named_parameters.baseline.txt b/pkg/kernel/testcases/strong-mode/named_parameters.baseline.txt
index 279ed4a..b296c16 100644
--- a/pkg/kernel/testcases/strong-mode/named_parameters.baseline.txt
+++ b/pkg/kernel/testcases/strong-mode/named_parameters.baseline.txt
@@ -1,5 +1,3 @@
-// ({alpha: dynamic, beta: dynamic}) → dynamic is not a subtype of ({beta: dynamic, alpha: dynamic}) → dynamic (no location)
-// ({beta: dynamic, alpha: dynamic}) → dynamic is not a subtype of ({alpha: dynamic, beta: dynamic}) → dynamic (no location)
 library;
 import self as self;
 import "dart:core" as core;
diff --git a/pkg/pkg.status b/pkg/pkg.status
index 17e515b..a4a5ef4 100644
--- a/pkg/pkg.status
+++ b/pkg/pkg.status
@@ -11,14 +11,18 @@
 */*/*/*/packages/*/*: Skip
 */*/*/*/*/packages/*/*: Skip
 
-# Don't run dev_compiler tests
-dev_compiler/test/*: Skip
-
 # Analyzer2dart is not maintained anymore.
 analyzer2dart/test/*: Skip
 
 dart_messages/test/dart_messages_test: Skip  # Requires a package root.
 
+# Skip dev_compiler codegen tests
+dev_compiler/test/codegen/*: Skip
+
+# Analyze dev_compiler but don't run its tests
+[ $compiler != dart2analyzer ]
+dev_compiler/test/*: Skip
+
 [ $compiler == dart2analyzer ]
 dev_compiler/gen/*: SkipByDesign
 
@@ -85,6 +89,9 @@
 analyzer/test/generated/java_core_test: Pass, Timeout # Issue 19747
 typed_data/test/typed_buffers_test/none: Fail # Issue 17607 (I put this here explicitly, since this is not the same as on ie9)
 
+[ $runtime == ie11 ]
+kernel/test/verify_test: Skip # Times out. Issue 27935
+
 [ $runtime == safarimobilesim ]
 # Unexplained errors only occuring on Safari 6.1 and earlier.
 typed_data/test/typed_buffers_test: RuntimeError
@@ -113,6 +120,9 @@
 observe/test/unique_message_test: SkipByDesign  # Uses dart:io.
 dart_messages/test/dart_messages_test: Skip  # Uses dart:io.
 
+[ $browser || $jscl ]
+kernel/test/*: SkipByDesign # Uses dart:io and bigints.
+
 [ $runtime == vm && ($arch == simarm64 || $arch == simarm || $arch == simarmv6 || $arch == simarmv5te || $arch == simmips || $arch == armv6 || $arch == armv5te) ]
 # Timeout. These are not unit tests. They do not run efficiently on our
 # simulator or low-end devices.
@@ -187,7 +197,7 @@
 analyzer/test/src/task/strong_mode_test: Crash # Issue 24485
 analyzer/test/src/task/yaml_test: Crash # Issue 24485
 
-[ $noopt || $runtime == dart_precompiled || $runtime == dart_app ]
+[ $noopt || $runtime == dart_precompiled ]
 *: SkipByDesign # The pkg test framework imports dart:mirrors.
 
 [ $compiler == dart2js && $cps_ir && $checked ]
diff --git a/pkg/pkgbuild.status b/pkg/pkgbuild.status
index cefeb2f..a4ad40d 100644
--- a/pkg/pkgbuild.status
+++ b/pkg/pkgbuild.status
@@ -9,6 +9,7 @@
 pkg/dev_compiler: SkipByDesign # we have relative paths to analyzer
 pkg/analyzer: Fail # Issue 27654
 pkg/front_end: Fail # Issue 27655
+pkg/kernel: Fail # Issue 27937
 
 [ $use_repository_packages ]
- # third_party/pkg/dart2js_info: Fail # Issue https://github.com/dart-lang/dart2js_info/pull/14
+third_party/pkg_tested/dart_style: Fail # Issue https://github.com/dart-lang/dart_style/issues/562
\ No newline at end of file
diff --git a/runtime/PRESUBMIT.py b/runtime/PRESUBMIT.py
index 0170f2f9..44c53df 100644
--- a/runtime/PRESUBMIT.py
+++ b/runtime/PRESUBMIT.py
@@ -5,6 +5,7 @@
 import os
 import cpplint
 import re
+import StringIO
 
 # memcpy does not handle overlapping memory regions. Even though this
 # is well documented it seems to be used in error quite often. To avoid
@@ -49,7 +50,17 @@
 
 
 def CheckFormatted(input_api, output_api):
-  return input_api.canned_checks.CheckPatchFormatted(input_api, output_api)
+  def convert_warning_to_error(presubmit_result):
+    if not presubmit_result.fatal:
+      # Convert this warning to an error.
+      stream = StringIO.StringIO()
+      presubmit_result.handle(stream)
+      message = stream.getvalue()
+      return output_api.PresubmitError(message)
+    return presubmit_result
+
+  results = input_api.canned_checks.CheckPatchFormatted(input_api, output_api)
+  return [convert_warning_to_error(r) for r in results]
 
 
 def CheckChangeOnUpload(input_api, output_api):
diff --git a/runtime/bin/BUILD.gn b/runtime/bin/BUILD.gn
index 903cc40..07b9b17 100644
--- a/runtime/bin/BUILD.gn
+++ b/runtime/bin/BUILD.gn
@@ -764,10 +764,15 @@
 }
 
 executable("run_vm_tests") {
+  if (defined(is_fuchsia) && is_fuchsia) {
+    testonly = true
+  }
+
   configs += [
     "..:dart_config",
     "..:dart_maybe_product_config",
   ]
+
   deps = [
     ":dart_snapshot_cc",
     ":generate_snapshot_test_dat_file",
diff --git a/runtime/bin/eventhandler_fuchsia.cc b/runtime/bin/eventhandler_fuchsia.cc
index c298e22..39be1ff 100644
--- a/runtime/bin/eventhandler_fuchsia.cc
+++ b/runtime/bin/eventhandler_fuchsia.cc
@@ -449,6 +449,10 @@
   while (!handler_impl->shutdown_) {
     int64_t millis = handler_impl->GetTimeout();
     ASSERT((millis == kInfinityTimeout) || (millis >= 0));
+    // TODO(US-109): When the epoll implementation is properly edge-triggered,
+    // remove this sleep, which prevents the message queue from being
+    // overwhelmed and leading to memory exhaustion.
+    usleep(5000);
     LOG_INFO("epoll_wait(millis = %ld)\n", millis);
     intptr_t result = NO_RETRY_EXPECTED(
         epoll_wait(handler_impl->epoll_fd_, events, kMaxEvents, millis));
diff --git a/runtime/bin/hashmap_test.cc b/runtime/bin/hashmap_test.cc
index 47849e0..bad384b 100644
--- a/runtime/bin/hashmap_test.cc
+++ b/runtime/bin/hashmap_test.cc
@@ -171,7 +171,7 @@
 }
 
 
-UNIT_TEST_CASE(Set) {
+UNIT_TEST_CASE(HashMap_Basic) {
   TestSet(WordHash, 100);
   TestSet(Hash, 100);
   TestSet(CollisionHash1, 50);
diff --git a/runtime/bin/run_vm_tests_fuchsia.cc b/runtime/bin/run_vm_tests_fuchsia.cc
index 71cf5c3..46e16e6 100644
--- a/runtime/bin/run_vm_tests_fuchsia.cc
+++ b/runtime/bin/run_vm_tests_fuchsia.cc
@@ -32,17 +32,9 @@
   "Read",
   "FileLength",
   "FilePosition",
-  // Crash in abort() and then hang. (MG-252)
-  "ArrayLengthMaxElements",
-  "Int8ListLengthMaxElements",
-  "ArrayNew_Overflow_Crash",
-  "SNPrint_BadArgs",
-  "IsolateReload_PendingUnqualifiedCall_InstanceToStatic",
-  "IsolateReload_PendingUnqualifiedCall_StaticToInstance",
-  "IsolateReload_PendingConstructorCall_AbstractToConcrete",
-  "IsolateReload_PendingConstructorCall_ConcreteToAbstract",
-  "IsolateReload_PendingStaticCall_DefinedToNSM",
-  "IsolateReload_PendingStaticCall_NSMToDefined",
+  // No realpath, files not in image.
+  "Dart2JSCompilerStats",
+  "Dart2JSCompileAll",
   // The profiler is turned off.
   "Profiler_AllocationSampleTest",
   "Profiler_ArrayAllocation",
@@ -69,27 +61,6 @@
   "Profiler_TypedArrayAllocation",
   "Profiler_GetSourceReport",
   "Service_Profile",
-  // No realpath, files not in image.
-  "Dart2JSCompilerStats",
-  "Dart2JSCompileAll",
-  // Uses too much memory.
-  "PrintJSON",
-  // Need OS::GetCurrentThreadCPUMicros.
-  // Skipping because they crash and hang. (MG-252)
-  "Timeline_Dart_TimelineGetTrace",
-  "Timeline_Dart_TimelineGetTraceOnlyDartEvents",
-  "Timeline_Dart_TimelineGetTraceWithDartEvents",
-  "Timeline_Dart_TimelineGetTraceGlobalOverride",
-  "Timeline_Dart_GlobalTimelineGetTrace",
-  "Timeline_Dart_GlobalTimelineGetTrace_Threaded",
-  "TimelineEventDuration",
-  "TimelineEventDurationPrintJSON",
-  "TimelineEventArguments",
-  "TimelineEventArgumentsPrintJSON",
-  "TimelineEventCallbackRecorderBasic",
-  "TimelineAnalysis_ThreadBlockCount",
-  "TimelineRingRecorderJSONOrder",
-  "TimelinePauses_BeginEnd",
 };
 
 // Expected to fail/crash.
@@ -99,14 +70,40 @@
   "Fail2",
   "AllocGeneric_Overflow",
   "CodeImmutability",
-  // Assumes initial thread's stack is the same size as spawned thread stacks.
-  "StackOverflowStacktraceInfo",
+  "IsolateReload_PendingUnqualifiedCall_StaticToInstance",
+  "IsolateReload_PendingConstructorCall_AbstractToConcrete",
+  "IsolateReload_PendingConstructorCall_ConcreteToAbstract",
+  "IsolateReload_PendingUnqualifiedCall_InstanceToStatic",
+  "IsolateReload_PendingStaticCall_DefinedToNSM",
+  "IsolateReload_PendingStaticCall_NSMToDefined",
+  "ArrayNew_Overflow_Crash",
+  "SNPrint_BadArgs",
 };
 
 // Bugs to fix, or things that are not yet implemented.
 const char* kBugs[] = {
-  // Needs read of RSS.
-  "InitialRSS",
+  // Need OS::GetCurrentThreadCPUMicros.
+  "Timeline_Dart_TimelineGetTraceOnlyDartEvents",
+  "Timeline_Dart_TimelineGetTraceWithDartEvents",
+  "Timeline_Dart_GlobalTimelineGetTrace",
+  "TimelineEventDuration",
+  "TimelineEventDurationPrintJSON",
+  "TimelineEventArguments",
+  "TimelineEventArgumentsPrintJSON",
+  "TimelineEventCallbackRecorderBasic",
+  "TimelineAnalysis_ThreadBlockCount",
+  "TimelineRingRecorderJSONOrder",
+  "TimelinePauses_BeginEnd",
+  "Timeline_Dart_TimelineGetTrace",
+  "Timeline_Dart_TimelineGetTraceGlobalOverride",
+  "Timeline_Dart_GlobalTimelineGetTrace_Threaded",
+
+  // Need VirtualMemory reservation with mmap.
+  "ArrayLengthMaxElements",
+  "Int8ListLengthMaxElements",
+
+  // Assumes initial thread's stack is the same size as spawned thread stacks.
+  "StackOverflowStacktraceInfo",
 };
 // clang-format on
 
diff --git a/runtime/bin/secure_socket_boringssl.cc b/runtime/bin/secure_socket_boringssl.cc
index 90d22fb..280d1f7 100644
--- a/runtime/bin/secure_socket_boringssl.cc
+++ b/runtime/bin/secure_socket_boringssl.cc
@@ -55,6 +55,17 @@
 Mutex* SSLFilter::mutex_ = new Mutex();
 int SSLFilter::filter_ssl_index;
 
+const intptr_t SSLFilter::kInternalBIOSize = 10 * KB;
+const intptr_t SSLFilter::kApproximateSize =
+    sizeof(SSLFilter) + (2 * SSLFilter::kInternalBIOSize);
+
+// The security context won't necessarily use the compiled-in root certificates,
+// but since there is no way to update the size of the allocation after creating
+// the weak persistent handle, we assume that it will. Note that when the
+// root certs aren't compiled in, |root_certificates_pem_length| is 0.
+const intptr_t SSLContext::kApproximateSize =
+    sizeof(SSLContext) + root_certificates_pem_length;
+
 static const int kSSLFilterNativeFieldIndex = 0;
 static const int kSecurityContextNativeFieldIndex = 0;
 static const int kX509NativeFieldIndex = 0;
@@ -64,11 +75,9 @@
 
 static const int SSL_ERROR_MESSAGE_BUFFER_SIZE = 1000;
 
-
 const char* commandline_root_certs_file = NULL;
 const char* commandline_root_certs_cache = NULL;
 
-
 /* Get the error messages from BoringSSL, and put them in buffer as a
  * null-terminated string. */
 static void FetchErrorString(char* buffer, int length) {
@@ -141,7 +150,7 @@
                                   reinterpret_cast<intptr_t>(filter));
   RETURN_IF_ERROR(err);
   Dart_NewWeakPersistentHandle(dart_this, reinterpret_cast<void*>(filter),
-                               sizeof(*filter), DeleteFilter);
+                               SSLFilter::kApproximateSize, DeleteFilter);
   return Dart_Null();
 }
 
@@ -167,7 +176,6 @@
 
 static Dart_Handle SetSecurityContext(Dart_NativeArguments args,
                                       SSLContext* context) {
-  const int approximate_size_of_context = 1500;
   Dart_Handle dart_this = Dart_GetNativeArgument(args, 0);
   RETURN_IF_ERROR(dart_this);
   ASSERT(Dart_IsInstance(dart_this));
@@ -175,7 +183,7 @@
       Dart_SetNativeInstanceField(dart_this, kSecurityContextNativeFieldIndex,
                                   reinterpret_cast<intptr_t>(context));
   RETURN_IF_ERROR(err);
-  Dart_NewWeakPersistentHandle(dart_this, context, approximate_size_of_context,
+  Dart_NewWeakPersistentHandle(dart_this, context, SSLContext::kApproximateSize,
                                DeleteSecurityContext);
   return Dart_Null();
 }
@@ -330,11 +338,16 @@
 }
 
 
+static intptr_t EstimateX509Size(X509* certificate) {
+  intptr_t length = i2d_X509(certificate, NULL);
+  return length > 0 ? length : 0;
+}
+
+
 // Returns the handle for a Dart object wrapping the X509 certificate object.
 // The caller should own a reference to the X509 object whose reference count
 // won't drop to zero before the ReleaseCertificate finalizer runs.
 static Dart_Handle WrappedX509Certificate(X509* certificate) {
-  const intptr_t approximate_size_of_certificate = 1500;
   if (certificate == NULL) {
     return Dart_Null();
   }
@@ -358,6 +371,9 @@
     X509_free(certificate);
     return status;
   }
+  const intptr_t approximate_size_of_certificate =
+      sizeof(*certificate) + EstimateX509Size(certificate);
+  ASSERT(approximate_size_of_certificate > 0);
   Dart_NewWeakPersistentHandle(result, reinterpret_cast<void*>(certificate),
                                approximate_size_of_certificate,
                                ReleaseCertificate);
@@ -1496,7 +1512,8 @@
   int status;
   int error;
   BIO* ssl_side;
-  status = BIO_new_bio_pair(&ssl_side, 10000, &socket_side_, 10000);
+  status = BIO_new_bio_pair(&ssl_side, kInternalBIOSize, &socket_side_,
+                            kInternalBIOSize);
   CheckStatus(status, "TlsException", "BIO_new_bio_pair");
 
   assert(context != NULL);
@@ -1505,10 +1522,6 @@
   SSL_set_mode(ssl_, SSL_MODE_AUTO_RETRY);  // TODO(whesse): Is this right?
   SSL_set_ex_data(ssl_, filter_ssl_index, this);
 
-#if defined(TARGET_OS_FUCHSIA)
-  // Temporary workaround until we isolate the memory leak issue.
-  SSL_set_verify(ssl_, SSL_VERIFY_NONE, NULL);
-#else
   if (is_server_) {
     int certificate_mode =
         request_client_certificate ? SSL_VERIFY_PEER : SSL_VERIFY_NONE;
@@ -1533,7 +1546,6 @@
     CheckStatus(status, "TlsException",
                 "Set hostname for certificate checking");
   }
-#endif  // defined(TARGET_OS_FUCHSIA)
   // Make the connection:
   if (is_server_) {
     status = SSL_accept(ssl_);
diff --git a/runtime/bin/secure_socket_boringssl.h b/runtime/bin/secure_socket_boringssl.h
index a24194a..974a57e 100644
--- a/runtime/bin/secure_socket_boringssl.h
+++ b/runtime/bin/secure_socket_boringssl.h
@@ -35,6 +35,8 @@
 
 class SSLContext {
  public:
+  static const intptr_t kApproximateSize;
+
   explicit SSLContext(SSL_CTX* context)
       : context_(context), alpn_protocol_string_(NULL) {}
 
@@ -81,6 +83,8 @@
     kFirstEncrypted = kReadEncrypted
   };
 
+  static const intptr_t kApproximateSize;
+
   SSLFilter()
       : callback_error(NULL),
         ssl_(NULL),
@@ -133,6 +137,7 @@
   BIO* socket_side_;
 
  private:
+  static const intptr_t kInternalBIOSize;
   static bool library_initialized_;
   static Mutex* mutex_;  // To protect library initialization.
 
diff --git a/runtime/bin/socket.cc b/runtime/bin/socket.cc
index d520572..cbb9a2c 100644
--- a/runtime/bin/socket.cc
+++ b/runtime/bin/socket.cc
@@ -196,7 +196,8 @@
 }
 
 
-bool ListeningSocketRegistry::CloseOneSafe(OSSocket* os_socket) {
+bool ListeningSocketRegistry::CloseOneSafe(OSSocket* os_socket,
+                                           bool update_hash_maps) {
   ASSERT(!mutex_->TryLock());
   ASSERT(os_socket != NULL);
   ASSERT(os_socket->ref_count > 0);
@@ -204,26 +205,28 @@
   if (os_socket->ref_count > 0) {
     return false;
   }
-  // We free the OS socket by removing it from two datastructures.
-  RemoveByFd(os_socket->socketfd);
+  if (update_hash_maps) {
+    // We free the OS socket by removing it from two datastructures.
+    RemoveByFd(os_socket->socketfd);
 
-  OSSocket* prev = NULL;
-  OSSocket* current = LookupByPort(os_socket->port);
-  while (current != os_socket) {
-    ASSERT(current != NULL);
-    prev = current;
-    current = current->next;
-  }
+    OSSocket* prev = NULL;
+    OSSocket* current = LookupByPort(os_socket->port);
+    while (current != os_socket) {
+      ASSERT(current != NULL);
+      prev = current;
+      current = current->next;
+    }
 
-  if ((prev == NULL) && (current->next == NULL)) {
-    // Remove last element from the list.
-    RemoveByPort(os_socket->port);
-  } else if (prev == NULL) {
-    // Remove first element of the list.
-    InsertByPort(os_socket->port, current->next);
-  } else {
-    // Remove element from the list which is not the first one.
-    prev->next = os_socket->next;
+    if ((prev == NULL) && (current->next == NULL)) {
+      // Remove last element from the list.
+      RemoveByPort(os_socket->port);
+    } else if (prev == NULL) {
+      // Remove first element of the list.
+      InsertByPort(os_socket->port, current->next);
+    } else {
+      // Remove element from the list which is not the first one.
+      prev->next = os_socket->next;
+    }
   }
 
   ASSERT(os_socket->ref_count == 0);
@@ -234,9 +237,10 @@
 
 void ListeningSocketRegistry::CloseAllSafe() {
   MutexLocker ml(mutex_);
-  for (HashMap::Entry* p = sockets_by_fd_.Start(); p != NULL;
-       p = sockets_by_fd_.Next(p)) {
-    CloseOneSafe(reinterpret_cast<OSSocket*>(p->value));
+
+  for (HashMap::Entry* cursor = sockets_by_fd_.Start(); cursor != NULL;
+       cursor = sockets_by_fd_.Next(cursor)) {
+    CloseOneSafe(reinterpret_cast<OSSocket*>(cursor->value), false);
   }
 }
 
@@ -245,7 +249,7 @@
   ASSERT(!mutex_->TryLock());
   OSSocket* os_socket = LookupByFd(socketfd);
   if (os_socket != NULL) {
-    return CloseOneSafe(os_socket);
+    return CloseOneSafe(os_socket, true);
   } else {
     // It should be impossible for the event handler to close something that
     // hasn't been created before.
diff --git a/runtime/bin/socket.h b/runtime/bin/socket.h
index 35d4acc..1afc05e 100644
--- a/runtime/bin/socket.h
+++ b/runtime/bin/socket.h
@@ -469,7 +469,7 @@
   void InsertByFd(intptr_t fd, OSSocket* socket);
   void RemoveByFd(intptr_t fd);
 
-  bool CloseOneSafe(OSSocket* os_socket);
+  bool CloseOneSafe(OSSocket* os_socket, bool update_hash_maps);
   void CloseAllSafe();
 
   HashMap sockets_by_port_;
diff --git a/runtime/observatory/lib/src/elements/debugger.dart b/runtime/observatory/lib/src/elements/debugger.dart
index 8b91eff..b3ca569 100644
--- a/runtime/observatory/lib/src/elements/debugger.dart
+++ b/runtime/observatory/lib/src/elements/debugger.dart
@@ -209,7 +209,8 @@
       debugger.downFrame(count);
       debugger.console.print('frame = ${debugger.currentFrame}');
     } catch (e) {
-      debugger.console.print('frame must be in range [${e.start},${e.end-1}]');
+      debugger.console.print(
+          'frame must be in range [${e.start}..${e.end-1}]');
     }
     return new Future.value(null);
   }
@@ -243,7 +244,8 @@
       debugger.upFrame(count);
       debugger.console.print('frame = ${debugger.currentFrame}');
     } on RangeError catch (e) {
-      debugger.console.print('frame must be in range [${e.start},${e.end-1}]');
+      debugger.console.print(
+          'frame must be in range [${e.start}..${e.end-1}]');
     }
     return new Future.value(null);
   }
@@ -279,7 +281,8 @@
       debugger.currentFrame = frame;
       debugger.console.print('frame = ${debugger.currentFrame}');
     } on RangeError catch (e) {
-      debugger.console.print('frame must be in range [${e.start},${e.end-1}]');
+      debugger.console.print(
+          'frame must be in range [${e.start}..${e.end-1}]');
     }
     return new Future.value(null);
   }
@@ -403,6 +406,73 @@
       'Syntax: step\n';
 }
 
+class RewindCommand extends DebuggerCommand {
+  RewindCommand(Debugger debugger) : super(debugger, 'rewind', []);
+
+  Future run(List<String> args) async {
+    try {
+      int count = 1;
+      if (args.length == 1) {
+        count = int.parse(args[0]);
+      } else if (args.length > 1) {
+        debugger.console.print('rewind expects 0 or 1 argument');
+        return;
+      } else if (count < 1 || count > debugger.stackDepth) {
+        debugger.console.print(
+            'frame must be in range [1..${debugger.stackDepth - 1}]');
+        return;
+      }
+      await debugger.rewind(count);
+    } on S.ServerRpcException catch(e) {
+      if (e.code == S.ServerRpcException.kCannotResume) {
+        debugger.console.printRed(e.data['details']);
+      } else {
+        rethrow;
+      }
+    }
+  }
+
+  String helpShort = 'Rewind the stack to a previous frame';
+
+  String helpLong =
+      'Rewind the stack to a previous frame.\n'
+      '\n'
+      'Syntax: rewind\n'
+      '        rewind <count>\n';
+}
+
+class ReloadCommand extends DebuggerCommand {
+  ReloadCommand(Debugger debugger) : super(debugger, 'reload', []);
+
+  Future run(List<String> args) async {
+    try {
+      int count = 1;
+      if (args.length > 0) {
+        debugger.console.print('reload expects no arguments');
+        return;
+      }
+      await debugger.isolate.reloadSources();
+      debugger.console.print('reload complete');
+      await debugger.refreshStack();
+    } on S.ServerRpcException catch(e) {
+      if (e.code == S.ServerRpcException.kIsolateReloadBarred ||
+          e.code == S.ServerRpcException.kIsolateReloadFailed ||
+          e.code == S.ServerRpcException.kIsolateIsReloading) {
+        debugger.console.printRed(e.data['details']);
+      } else {
+        rethrow;
+      }
+    }
+  }
+
+  String helpShort = 'Reload the sources for the current isolate';
+
+  String helpLong =
+      'Reload the sources for the current isolate.\n'
+      '\n'
+      'Syntax: reload\n';
+}
+
 class ClsCommand extends DebuggerCommand {
   ClsCommand(Debugger debugger) : super(debugger, 'cls', []) {}
 
@@ -663,8 +733,8 @@
         var script = loc.script;
         await script.load();
         if (loc.line < 1 || loc.line > script.lines.length) {
-          debugger.console
-              .print('line number must be in range [1,${script.lines.length}]');
+          debugger.console.print(
+              'line number must be in range [1..${script.lines.length}]');
           return;
         }
         try {
@@ -744,7 +814,7 @@
     var script = loc.script;
     if (loc.line < 1 || loc.line > script.lines.length) {
       debugger.console
-          .print('line number must be in range [1,${script.lines.length}]');
+          .print('line number must be in range [1..${script.lines.length}]');
       return;
     }
     var lineInfo = script.getLine(loc.line);
@@ -899,7 +969,6 @@
       : super(debugger, 'isolate', [
           new IsolateListCommand(debugger),
           new IsolateNameCommand(debugger),
-          new IsolateReloadCommand(debugger),
         ]) {
     alias = 'i';
   }
@@ -1042,27 +1111,6 @@
       'Syntax: isolate name <name>\n';
 }
 
-class IsolateReloadCommand extends DebuggerCommand {
-  IsolateReloadCommand(Debugger debugger) : super(debugger, 'reload', []);
-
-  Future run(List<String> args) async {
-    if (debugger.isolate == null) {
-      debugger.console.print('There is no current vm');
-      return;
-    }
-
-    await debugger.isolate.reloadSources();
-
-    debugger.console.print('Isolate reloading....');
-  }
-
-  String helpShort = 'Reload the sources for the current isolate.';
-
-  String helpLong = 'Reload the sources for the current isolate.\n'
-      '\n'
-      'Syntax: reload\n';
-}
-
 class InfoCommand extends DebuggerCommand {
   InfoCommand(Debugger debugger)
       : super(debugger, 'info', [
@@ -1371,7 +1419,9 @@
       new LogCommand(this),
       new PauseCommand(this),
       new PrintCommand(this),
+      new ReloadCommand(this),
       new RefreshCommand(this),
+      new RewindCommand(this),
       new SetCommand(this),
       new SmartNextCommand(this),
       new StepCommand(this),
@@ -1879,6 +1929,20 @@
       return new Future.value(null);
     }
   }
+
+  Future rewind(int count) {
+    if (isolatePaused()) {
+      var event = isolate.pauseEvent;
+      if (event is M.PauseExitEvent) {
+        console.print("Type 'continue' [F7] to exit the isolate");
+        return new Future.value(null);
+      }
+      return isolate.rewind(count);
+    } else {
+      console.print('The program must be paused');
+      return new Future.value(null);
+    }
+  }
 }
 
 class DebuggerPageElement extends HtmlElement implements Renderable {
@@ -1905,6 +1969,7 @@
     final e = document.createElement(tag.name);
     final debugger = new ObservatoryDebugger(isolate);
     debugger.page = e;
+    debugger.instances = instances;
     e._isolate = isolate;
     e._debugger = debugger;
     e._instances = instances;
@@ -2513,7 +2578,9 @@
   }
 
   bool matchFrame(S.Frame newFrame) {
-    return newFrame.function.id == _frame.function.id;
+    return (newFrame.function.id == _frame.function.id &&
+            newFrame.location.script.id ==
+            frame.location.script.id);
   }
 
   void updateFrame(S.Frame newFrame) {
diff --git a/runtime/observatory/lib/src/service/object.dart b/runtime/observatory/lib/src/service/object.dart
index c3ea07da..58ef53f 100644
--- a/runtime/observatory/lib/src/service/object.dart
+++ b/runtime/observatory/lib/src/service/object.dart
@@ -42,11 +42,13 @@
   static const kStreamNotSubscribed = 104;
   static const kIsolateMustBeRunnable = 105;
   static const kIsolateMustBePaused = 106;
+  static const kCannotResume = 107;
   static const kIsolateIsReloading = 1000;
   static const kFileSystemAlreadyExists = 1001;
   static const kFileSystemDoesNotExist = 1002;
   static const kFileDoesNotExist = 1003;
   static const kIsolateReloadFailed = 1004;
+  static const kIsolateReloadBarred = 1005;
 
   int code;
   Map data;
@@ -1279,7 +1281,6 @@
   bool loading = true;
   bool runnable = false;
   bool ioEnabled = false;
-  bool reloading = false;
   M.IsolateStatus get status {
     if (paused) {
       return M.IsolateStatus.paused;
@@ -1344,13 +1345,12 @@
       params['pause'] = pause;
     }
     return invokeRpc('reloadSources', params).then((result) {
-      reloading = true;
+      _cache.clear();
       return result;
     });
   }
 
   void _handleIsolateReloadEvent(ServiceEvent event) {
-    reloading = false;
     if (event.reloadError != null) {
       // Failure.
       print('Reload failed: ${event.reloadError}');
@@ -1777,6 +1777,10 @@
     return invokeRpc('resume', {'step': 'Out'});
   }
 
+  Future rewind(int count) {
+    return invokeRpc('resume', {'step': 'Rewind', 'frameIndex': count});
+  }
+
   Future setName(String newName) {
     return invokeRpc('setName', {'name': newName});
   }
diff --git a/runtime/observatory/tests/service/pause_idle_isolate_test.dart b/runtime/observatory/tests/service/pause_idle_isolate_test.dart
index 484230b..d042f4b 100644
--- a/runtime/observatory/tests/service/pause_idle_isolate_test.dart
+++ b/runtime/observatory/tests/service/pause_idle_isolate_test.dart
@@ -52,5 +52,6 @@
 
 main(args) => runIsolateTests(args, tests,
                               testeeConcurrent: testMain,
-                              trace_service: true,
-                              verbose_vm: true);
+                              verbose_vm: true,
+                              extraArgs: [ '--trace-service',
+                                           '--trace-service-verbose' ]);
diff --git a/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart b/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart
index 146be22..b292b31 100644
--- a/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart
+++ b/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart
@@ -86,5 +86,6 @@
                               testeeConcurrent: testMain,
                               pause_on_start: true,
                               pause_on_exit: true,
-                              trace_service: true,
-                              verbose_vm: true);
+                              verbose_vm: true,
+                              extraArgs: [ '--trace-service',
+                                           '--trace-service-verbose' ]);
diff --git a/runtime/observatory/tests/service/pause_on_start_then_step_test.dart b/runtime/observatory/tests/service/pause_on_start_then_step_test.dart
index 107d2ee..480d984 100644
--- a/runtime/observatory/tests/service/pause_on_start_then_step_test.dart
+++ b/runtime/observatory/tests/service/pause_on_start_then_step_test.dart
@@ -89,5 +89,6 @@
                               testeeConcurrent: testMain,
                               pause_on_start: true,
                               pause_on_exit: true,
-                              trace_service: true,
-                              verbose_vm: true);
+                              verbose_vm: true,
+                              extraArgs: [ '--trace-service',
+                                           '--trace-service-verbose' ]);
diff --git a/runtime/observatory/tests/service/rewind_optimized_out_test.dart b/runtime/observatory/tests/service/rewind_optimized_out_test.dart
new file mode 100644
index 0000000..23b8c9a
--- /dev/null
+++ b/runtime/observatory/tests/service/rewind_optimized_out_test.dart
@@ -0,0 +1,86 @@
+// 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.
+// VMOptions=--error_on_bad_type --error_on_bad_override
+
+import 'dart:developer';
+import 'package:observatory/service_io.dart';
+import 'package:unittest/unittest.dart';
+import 'service_test_common.dart';
+import 'test_helper.dart';
+
+const alwaysInline = "AlwaysInline";
+const noInline = "NeverInline";
+
+int LINE_A = 35;
+int LINE_B = 40;
+int LINE_C = 43;
+int LINE_D = 47;
+
+int global = 0;
+
+@noInline
+b3(x) {
+  int sum = 0;
+  try {
+    for (int i = 0; i < x; i++) {
+      sum += x;
+    }
+  } catch (e) {
+    print("caught $e");
+  }
+  if (global >= 100) {
+    debugger();
+  }
+  global = global + 1;  // Line A
+  return sum;
+}
+
+@alwaysInline
+b2(x) => b3(x);  // Line B
+
+@alwaysInline
+b1(x) => b2(x);  // Line C
+
+test() {
+  while (true) {
+    b1(10000);  // Line D
+  }
+}
+
+var tests = [
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_A),
+
+  (Isolate isolate) async {
+    // We are at our breakpoint with global=100.
+    var result = await isolate.rootLibrary.evaluate('global');
+    print('global is $result');
+    expect(result.type, equals('Instance'));
+    expect(result.valueAsString, equals('100'));
+
+    // Rewind the top stack frame.
+    bool caughtException;
+    try {
+      result = await isolate.rewind(1);
+      expect(false, isTrue, reason:'Unreachable');
+    } on ServerRpcException catch(e) {
+      caughtException = true;
+      expect(e.code, equals(ServerRpcException.kCannotResume));
+      expect(e.message,
+             'Cannot rewind to frame 1 due to conflicting compiler '
+             'optimizations. Run the vm with --no-prune-dead-locals to '
+             'disallow these optimizations. Next valid rewind frame is 4.');
+    }
+    expect(caughtException, isTrue);
+  },
+];
+
+
+main(args) => runIsolateTests(args, tests, testeeConcurrent: test,
+                              extraArgs:
+                              ['--trace-rewind',
+                               '--prune-dead-locals',
+                               '--enable-inlining-annotations',
+                               '--no-background-compilation',
+                               '--optimization-counter-threshold=10']);
diff --git a/runtime/observatory/tests/service/rewind_test.dart b/runtime/observatory/tests/service/rewind_test.dart
new file mode 100644
index 0000000..152d711
--- /dev/null
+++ b/runtime/observatory/tests/service/rewind_test.dart
@@ -0,0 +1,173 @@
+// 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.
+// VMOptions=--error_on_bad_type --error_on_bad_override
+
+import 'dart:developer';
+import 'package:observatory/service_io.dart';
+import 'package:unittest/unittest.dart';
+import 'service_test_common.dart';
+import 'test_helper.dart';
+
+const alwaysInline = "AlwaysInline";
+const noInline = "NeverInline";
+
+int LINE_A = 35;
+int LINE_B = 40;
+int LINE_C = 43;
+int LINE_D = 47;
+
+int global = 0;
+
+@noInline
+b3(x) {
+  int sum = 0;
+  try {
+    for (int i = 0; i < x; i++) {
+      sum += x;
+    }
+  } catch (e) {
+    print("caught $e");
+  }
+  if (global >= 100) {
+    debugger();
+  }
+  global = global + 1;  // Line A
+  return sum;
+}
+
+@alwaysInline
+b2(x) => b3(x);  // Line B
+
+@alwaysInline
+b1(x) => b2(x);  // Line C
+
+test() {
+  while (true) {
+    b1(10000);  // Line D
+  }
+}
+
+var tests = [
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_A),
+
+  (Isolate isolate) async {
+    // We are not able to rewind frame 0.
+    bool caughtException;
+    try {
+      await isolate.rewind(0);
+      expect(false, isTrue, reason:'Unreachable');
+    } on ServerRpcException catch(e) {
+      caughtException = true;
+      expect(e.code, equals(ServerRpcException.kCannotResume));
+      expect(e.message, 'Frame must be in bounds [1..9]: saw 0');
+    }
+    expect(caughtException, isTrue);
+  },
+
+  (Isolate isolate) async {
+    // We are not able to rewind frame 10.
+    bool caughtException;
+    try {
+      await isolate.rewind(10);
+      expect(false, isTrue, reason:'Unreachable');
+    } on ServerRpcException catch(e) {
+      caughtException = true;
+      expect(e.code, equals(ServerRpcException.kCannotResume));
+      expect(e.message, 'Frame must be in bounds [1..9]: saw 10');
+    }
+    expect(caughtException, isTrue);
+  },
+
+  (Isolate isolate) async {
+    // We are at our breakpoint with global=100.
+    var result = await isolate.rootLibrary.evaluate('global');
+    print('global is $result');
+    expect(result.type, equals('Instance'));
+    expect(result.valueAsString, equals('100'));
+
+    // Rewind the top stack frame.
+    result = await isolate.rewind(1);
+    expect(result['type'], equals('Success'));
+  },
+
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_B),
+
+  (Isolate isolate) async {
+    var result = await isolate.resume();
+    expect(result['type'], equals('Success'));
+  },
+
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_A),
+
+  (Isolate isolate) async {
+    // global still is equal to 100.  We did not execute "global++".
+    var result = await isolate.rootLibrary.evaluate('global');
+    print('global is $result');
+    expect(result.type, equals('Instance'));
+    expect(result.valueAsString, equals('100'));
+
+    // Resume again, for fun.
+    result = await isolate.resume();
+    expect(result['type'], equals('Success'));
+  },
+
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_A),
+
+  (Isolate isolate) async {
+    // global is now 101.
+    var result = await isolate.rootLibrary.evaluate('global');
+    print('global is $result');
+    expect(result.type, equals('Instance'));
+    expect(result.valueAsString, equals('101'));
+
+    // Rewind up to 'test'/
+    result = await isolate.rewind(3);
+    expect(result['type'], equals('Success'));
+  },
+
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_D),
+
+  (Isolate isolate) async {
+    // Reset global to 0 and start again.
+    var result = await isolate.rootLibrary.evaluate('global=0');
+    print('set global to $result');
+    expect(result.type, equals('Instance'));
+    expect(result.valueAsString, equals('0'));
+
+    result = await isolate.resume();
+    expect(result['type'], equals('Success'));
+  },
+
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_A),
+
+  (Isolate isolate) async {
+    // We are at our breakpoint with global=100.
+    var result = await isolate.rootLibrary.evaluate('global');
+    print('global is $result');
+    expect(result.type, equals('Instance'));
+    expect(result.valueAsString, equals('100'));
+
+    // Rewind the top 2 stack frames.
+    result = await isolate.rewind(2);
+    expect(result['type'], equals('Success'));
+  },
+
+  hasStoppedAtBreakpoint,
+  stoppedAtLine(LINE_C),
+];
+
+
+main(args) => runIsolateTests(args, tests, testeeConcurrent: test,
+                              extraArgs:
+                              ['--trace-rewind',
+                               '--no-prune-dead-locals',
+                               '--enable-inlining-annotations',
+                               '--no-background-compilation',
+                               '--optimization-counter-threshold=10']);
diff --git a/runtime/observatory/tests/service/service.status b/runtime/observatory/tests/service/service.status
index ccbcbcc..72e4980 100644
--- a/runtime/observatory/tests/service/service.status
+++ b/runtime/observatory/tests/service/service.status
@@ -43,7 +43,7 @@
 [ $runtime == vm ]
 developer_extension_test: Pass, Fail # Issue 27225
 
-[ $runtime == dart_app ]
+[ $compiler == app_jit ]
 address_mapper_test: CompileTimeError # Issue 27806
 capture_stdio_test: CompileTimeError # Issue 27806
 complex_reload_test: RuntimeError # Issue 27806
@@ -64,6 +64,8 @@
 get_allocation_samples_test: RuntimeError # Profiling unimplemented.
 get_cpu_profile_timeline_rpc_test: RuntimeError # Profiling unimplemented.
 implicit_getter_setter_test: RuntimeError # Field guards unimplemented.
+rewind_test: RuntimeError # Issue 27878
+rewind_optimized_out_test: RuntimeError # Issue 27878
 
 [ $hot_reload || $hot_reload_rollback ]
 # Skip all service tests because random reloads interfere.
diff --git a/runtime/observatory/tests/service/service_test_common.dart b/runtime/observatory/tests/service/service_test_common.dart
index bf1d013..45e8b46 100644
--- a/runtime/observatory/tests/service/service_test_common.dart
+++ b/runtime/observatory/tests/service/service_test_common.dart
@@ -234,6 +234,10 @@
   return (Isolate isolate) async {
     print("Checking we are at line $line");
 
+    // Make sure that the isolate has stopped.
+    isolate.reload();
+    expect(isolate.pauseEvent is! M.ResumeEvent, isTrue);
+
     ServiceMap stack = await isolate.getStack();
     expect(stack.type, equals('Stack'));
 
diff --git a/runtime/observatory/tests/service/set_vm_name_rpc_test.dart b/runtime/observatory/tests/service/set_vm_name_rpc_test.dart
index 7e3a53a..8554ad3 100644
--- a/runtime/observatory/tests/service/set_vm_name_rpc_test.dart
+++ b/runtime/observatory/tests/service/set_vm_name_rpc_test.dart
@@ -32,4 +32,6 @@
   },
 ];
 
-main(args) async => runVMTests(args, tests, trace_service: true);
+main(args) async => runVMTests(args, tests,
+                               extraArgs: [ '--trace-service',
+                                            '--trace-service-verbose' ]);
diff --git a/runtime/observatory/tests/service/step_over_await_test.dart b/runtime/observatory/tests/service/step_over_await_test.dart
index 1bbb3b7..d5f946c 100644
--- a/runtime/observatory/tests/service/step_over_await_test.dart
+++ b/runtime/observatory/tests/service/step_over_await_test.dart
@@ -1,7 +1,7 @@
 // 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
 // BSD-style license that can be found in the LICENSE file.
-// VMOptions=--error_on_bad_type --error_on_bad_override  --verbose_debug --trace_service
+// VMOptions=--error_on_bad_type --error_on_bad_override  --verbose_debug
 
 import 'dart:async';
 import 'dart:developer';
diff --git a/runtime/observatory/tests/service/test_helper.dart b/runtime/observatory/tests/service/test_helper.dart
index a722876..eeb6805 100644
--- a/runtime/observatory/tests/service/test_helper.dart
+++ b/runtime/observatory/tests/service/test_helper.dart
@@ -90,15 +90,12 @@
   Future<Process> _spawnProcess(bool pause_on_start,
                                 bool pause_on_exit,
                                 bool pause_on_unhandled_exceptions,
-                                bool trace_service,
-                                bool trace_compiler,
                                 bool testeeControlsServer,
-                                bool useAuthToken) {
+                                bool useAuthToken,
+                                List<String> extraArgs) {
     assert(pause_on_start != null);
     assert(pause_on_exit != null);
     assert(pause_on_unhandled_exceptions != null);
-    assert(trace_service != null);
-    assert(trace_compiler != null);
     assert(testeeControlsServer != null);
     assert(useAuthToken != null);
 
@@ -106,39 +103,29 @@
       return _spawnSkyProcess(pause_on_start,
                               pause_on_exit,
                               pause_on_unhandled_exceptions,
-                              trace_service,
-                              trace_compiler,
-                              testeeControlsServer);
+                              testeeControlsServer,
+                              extraArgs);
     } else {
       return _spawnDartProcess(pause_on_start,
                                pause_on_exit,
                                pause_on_unhandled_exceptions,
-                               trace_service,
-                               trace_compiler,
                                testeeControlsServer,
-                               useAuthToken);
+                               useAuthToken,
+                               extraArgs);
     }
   }
 
   Future<Process> _spawnDartProcess(bool pause_on_start,
                                     bool pause_on_exit,
                                     bool pause_on_unhandled_exceptions,
-                                    bool trace_service,
-                                    bool trace_compiler,
                                     bool testeeControlsServer,
-                                    bool useAuthToken) {
+                                    bool useAuthToken,
+                                    List<String> extraArgs) {
     assert(!_shouldLaunchSkyShell());
 
     String dartExecutable = Platform.executable;
 
     var fullArgs = [];
-    if (trace_service) {
-      fullArgs.add('--trace-service');
-      fullArgs.add('--trace-service-verbose');
-    }
-    if (trace_compiler) {
-      fullArgs.add('--trace-compiler');
-    }
     if (pause_on_start) {
       fullArgs.add('--pause-isolates-on-start');
     }
@@ -148,6 +135,9 @@
     if (pause_on_unhandled_exceptions) {
       fullArgs.add('--pause-isolates-on-unhandled-exceptions');
     }
+    if (extraArgs != null) {
+      fullArgs.addAll(extraArgs);
+    }
 
     fullArgs.addAll(Platform.executableArguments);
     if (!testeeControlsServer) {
@@ -166,22 +156,14 @@
   Future<Process> _spawnSkyProcess(bool pause_on_start,
                                    bool pause_on_exit,
                                    bool pause_on_unhandled_exceptions,
-                                   bool trace_service,
-                                   bool trace_compiler,
-                                   bool testeeControlsServer) {
+                                   bool testeeControlsServer,
+                                   List<String> extraArgs) {
     assert(_shouldLaunchSkyShell());
 
     String dartExecutable = _skyShellPath();
 
     var dartFlags = [];
     var fullArgs = [];
-    if (trace_service) {
-      dartFlags.add('--trace_service');
-      dartFlags.add('--trace_service_verbose');
-    }
-    if (trace_compiler) {
-      dartFlags.add('--trace_compiler');
-    }
     if (pause_on_start) {
       dartFlags.add('--pause_isolates_on_start');
       fullArgs.add('--start-paused');
@@ -194,6 +176,9 @@
     }
     // Override mirrors.
     dartFlags.add('--enable_mirrors=true');
+    if (extraArgs != null) {
+      fullArgs.addAll(extraArgs);
+    }
 
     fullArgs.addAll(Platform.executableArguments);
     if (!testeeControlsServer) {
@@ -223,17 +208,15 @@
   Future<Uri> launch(bool pause_on_start,
                      bool pause_on_exit,
                      bool pause_on_unhandled_exceptions,
-                     bool trace_service,
-                     bool trace_compiler,
                      bool testeeControlsServer,
-                     bool useAuthToken) {
+                     bool useAuthToken,
+                     List<String> extraArgs) {
     return _spawnProcess(pause_on_start,
                   pause_on_exit,
                   pause_on_unhandled_exceptions,
-                  trace_service,
-                  trace_compiler,
                   testeeControlsServer,
-                  useAuthToken).then((p) {
+                  useAuthToken,
+                  extraArgs).then((p) {
       Completer<Uri> completer = new Completer<Uri>();
       process = p;
       Uri uri;
@@ -288,12 +271,11 @@
 
 class _ServiceTesterRunner {
   void run({List<String> mainArgs,
+            List<String> extraArgs,
             List<VMTest> vmTests,
             List<IsolateTest> isolateTests,
             bool pause_on_start: false,
             bool pause_on_exit: false,
-            bool trace_service: false,
-            bool trace_compiler: false,
             bool verbose_vm: false,
             bool pause_on_unhandled_exceptions: false,
             bool testeeControlsServer: false,
@@ -301,9 +283,8 @@
     var process = new _ServiceTesteeLauncher();
     process.launch(pause_on_start, pause_on_exit,
                    pause_on_unhandled_exceptions,
-                   trace_service, trace_compiler,
                    testeeControlsServer,
-                   useAuthToken).then((Uri serverAddress) async {
+                   useAuthToken, extraArgs).then((Uri serverAddress) async {
       if (mainArgs.contains("--gdb")) {
         var pid = process.process.pid;
         var wait = new Duration(seconds: 10);
@@ -364,12 +345,11 @@
                         testeeConcurrent(),
                         bool pause_on_start: false,
                         bool pause_on_exit: false,
-                        bool trace_service: false,
-                        bool trace_compiler: false,
                         bool verbose_vm: false,
                         bool pause_on_unhandled_exceptions: false,
                         bool testeeControlsServer: false,
-                        bool useAuthToken: false}) async {
+                        bool useAuthToken: false,
+                        List<String> extraArgs}) async {
   assert(!pause_on_start || testeeBefore == null);
   if (_isTestee()) {
     new _ServiceTesteeRunner().run(testeeBefore: testeeBefore,
@@ -379,11 +359,10 @@
   } else {
     new _ServiceTesterRunner().run(
         mainArgs: mainArgs,
+        extraArgs: extraArgs,
         isolateTests: tests,
         pause_on_start: pause_on_start,
         pause_on_exit: pause_on_exit,
-        trace_service: trace_service,
-        trace_compiler: trace_compiler,
         verbose_vm: verbose_vm,
         pause_on_unhandled_exceptions: pause_on_unhandled_exceptions,
         testeeControlsServer: testeeControlsServer,
@@ -406,10 +385,9 @@
                                  void testeeConcurrent(),
                                  bool pause_on_start: false,
                                  bool pause_on_exit: false,
-                                 bool trace_service: false,
-                                 bool trace_compiler: false,
                                  bool verbose_vm: false,
-                                 bool pause_on_unhandled_exceptions: false}) {
+                                 bool pause_on_unhandled_exceptions: false,
+                                 List<String> extraArgs}) {
   assert(!pause_on_start || testeeBefore == null);
   if (_isTestee()) {
     new _ServiceTesteeRunner().runSync(testeeBeforeSync: testeeBefore,
@@ -419,11 +397,10 @@
   } else {
     new _ServiceTesterRunner().run(
         mainArgs: mainArgs,
+        extraArgs: extraArgs,
         isolateTests: tests,
         pause_on_start: pause_on_start,
         pause_on_exit: pause_on_exit,
-        trace_service: trace_service,
-        trace_compiler: trace_compiler,
         verbose_vm: verbose_vm,
         pause_on_unhandled_exceptions: pause_on_unhandled_exceptions);
   }
@@ -440,10 +417,9 @@
                    testeeConcurrent(),
                    bool pause_on_start: false,
                    bool pause_on_exit: false,
-                   bool trace_service: false,
-                   bool trace_compiler: false,
                    bool verbose_vm: false,
-                   bool pause_on_unhandled_exceptions: false}) async {
+                   bool pause_on_unhandled_exceptions: false,
+                   List<String> extraArgs}) async {
   if (_isTestee()) {
     new _ServiceTesteeRunner().run(testeeBefore: testeeBefore,
                                    testeeConcurrent: testeeConcurrent,
@@ -452,11 +428,10 @@
   } else {
     new _ServiceTesterRunner().run(
         mainArgs: mainArgs,
+        extraArgs: extraArgs,
         vmTests: tests,
         pause_on_start: pause_on_start,
         pause_on_exit: pause_on_exit,
-        trace_service: trace_service,
-        trace_compiler: trace_compiler,
         verbose_vm: verbose_vm,
         pause_on_unhandled_exceptions: pause_on_unhandled_exceptions);
   }
diff --git a/runtime/platform/hashmap.cc b/runtime/platform/hashmap.cc
index 4611533..4a18cb2 100644
--- a/runtime/platform/hashmap.cc
+++ b/runtime/platform/hashmap.cc
@@ -106,7 +106,6 @@
 
   // Clear the candidate which will not break searching the hash table.
   candidate->key = NULL;
-  candidate->value = NULL;
   occupancy_--;
 }
 
@@ -118,7 +117,6 @@
     if ((clear != NULL) && (p->key != NULL)) {
       clear(p->value);
     }
-    p->value = NULL;
     p->key = NULL;
   }
   occupancy_ = 0;
diff --git a/runtime/platform/hashmap.h b/runtime/platform/hashmap.h
index 1fd1235..be8278e 100644
--- a/runtime/platform/hashmap.h
+++ b/runtime/platform/hashmap.h
@@ -61,6 +61,9 @@
   Entry* Lookup(void* key, uint32_t hash, bool insert);
 
   // Removes the entry with matching key.
+  //
+  // WARNING: This method cannot be called while iterating a `HashMap`
+  // otherwise the iteration might step over elements!
   void Remove(void* key, uint32_t hash);
 
   // Empties the hash map (occupancy() == 0), and calls the function 'clear' on
diff --git a/runtime/tests/vm/vm.status b/runtime/tests/vm/vm.status
index dd5b600..496a025 100644
--- a/runtime/tests/vm/vm.status
+++ b/runtime/tests/vm/vm.status
@@ -133,6 +133,9 @@
 [ $compiler == dart2analyzer ]
 dart/optimized_stacktrace_test: StaticWarning
 
+[ $compiler == app_jit ]
+dart/snapshot_version_test: Fail,OK # Expects to find script snapshot relative to Dart source.
+
 [ $runtime != vm ]
 dart/snapshot_version_test: SkipByDesign  # Spawns processes
 dart/spawn_infinite_loop_test: Skip  # VM shutdown test
@@ -159,7 +162,7 @@
 dart/inline_stack_frame_test: Pass, RuntimeError
 dart/optimized_stacktrace_test: Pass, RuntimeError
 
-[ $runtime == dart_app || $runtime == dart_precompiled ]
+[ $compiler == app_jit || $compiler == precompiler ]
 dart/data_uri_spawn_test: SkipByDesign # Isolate.spawnUri
 dart/optimized_stacktrace_test: SkipByDesign # Requires line numbers
 
diff --git a/runtime/tools/create_archive.py b/runtime/tools/create_archive.py
old mode 100644
new mode 100755
index 7b0e99d..76d42dc
--- a/runtime/tools/create_archive.py
+++ b/runtime/tools/create_archive.py
@@ -1,3 +1,4 @@
+#!/usr/bin/env python
 # 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
 # BSD-style license that can be found in the LICENSE file.
@@ -132,6 +133,9 @@
             continue
         files.append(src_path)
 
+    # Ensure consistent file ordering for reproducible builds.
+    files.sort()
+
     # Write out archive.
     makeArchive(options.tar_output,
                 options.client_root,
diff --git a/runtime/vm/code_generator.cc b/runtime/vm/code_generator.cc
index 4a35895..d0c0732 100644
--- a/runtime/vm/code_generator.cc
+++ b/runtime/vm/code_generator.cc
@@ -2215,6 +2215,15 @@
 }
 
 
+DEFINE_RUNTIME_ENTRY(RewindPostDeopt, 0) {
+#if !defined(DART_PRECOMPILED_RUNTIME)
+#if !defined(PRODUCT)
+  isolate->debugger()->RewindPostDeopt();
+#endif  // !PRODUCT
+#endif  // !DART_PRECOMPILED_RUNTIME
+  UNREACHABLE();
+}
+
 DEFINE_LEAF_RUNTIME_ENTRY(intptr_t,
                           BigintCompare,
                           2,
diff --git a/runtime/vm/dart_entry.cc b/runtime/vm/dart_entry.cc
index 3346bef..ae0f13f 100644
--- a/runtime/vm/dart_entry.cc
+++ b/runtime/vm/dart_entry.cc
@@ -551,7 +551,7 @@
     // If the isolate is being debugged and the debugger was stepping
     // through code, enable single stepping so debugger will stop
     // at the first location the user is interested in.
-    isolate->debugger()->SetSingleStep();
+    isolate->debugger()->SetResumeAction(Debugger::kStepInto);
   }
   const Object& result =
       Object::Handle(zone, DartEntry::InvokeFunction(function, args));
diff --git a/runtime/vm/debugger.cc b/runtime/vm/debugger.cc
index 3cdf810..5c54271 100644
--- a/runtime/vm/debugger.cc
+++ b/runtime/vm/debugger.cc
@@ -6,6 +6,8 @@
 
 #include "include/dart_api.h"
 
+#include "platform/address_sanitizer.h"
+
 #include "vm/code_generator.h"
 #include "vm/code_patcher.h"
 #include "vm/compiler.h"
@@ -42,6 +44,7 @@
             trace_debugger_stacktrace,
             false,
             "Trace debugger stacktrace collection");
+DEFINE_FLAG(bool, trace_rewind, false, "Trace frame rewind");
 DEFINE_FLAG(bool, verbose_debug, false, "Verbose debugger messages");
 DEFINE_FLAG(bool,
             steal_breakpoints,
@@ -850,6 +853,24 @@
 }
 
 
+bool ActivationFrame::IsRewindable() const {
+  if (deopt_frame_.IsNull()) {
+    return true;
+  }
+  // TODO(turnidge): This is conservative.  It looks at all values in
+  // the deopt_frame_ even though some of them may correspond to other
+  // inlined frames.
+  Object& obj = Object::Handle();
+  for (int i = 0; i < deopt_frame_.Length(); i++) {
+    obj = deopt_frame_.At(i);
+    if (obj.raw() == Symbols::OptimizedOut().raw()) {
+      return false;
+    }
+  }
+  return true;
+}
+
+
 void ActivationFrame::PrintContextMismatchError(intptr_t ctx_slot,
                                                 intptr_t frame_ctx_level,
                                                 intptr_t var_ctx_level) {
@@ -1108,9 +1129,13 @@
   }
 }
 
+static bool IsFunctionVisible(const Function& function) {
+  return FLAG_show_invisible_frames || function.is_visible();
+}
+
 
 void DebuggerStackTrace::AddActivation(ActivationFrame* frame) {
-  if (FLAG_show_invisible_frames || frame->function().is_visible()) {
+  if (IsFunctionVisible(frame->function())) {
     trace_.Add(frame);
   }
 }
@@ -1237,6 +1262,8 @@
       breakpoint_locations_(NULL),
       code_breakpoints_(NULL),
       resume_action_(kContinue),
+      resume_frame_index_(-1),
+      post_deopt_frame_index_(-1),
       ignore_breakpoints_(false),
       pause_event_(NULL),
       obj_cache_(NULL),
@@ -1300,10 +1327,13 @@
 }
 
 
-bool Debugger::SetupStepOverAsyncSuspension() {
+bool Debugger::SetupStepOverAsyncSuspension(const char** error) {
   ActivationFrame* top_frame = TopDartFrame();
   if (!IsAtAsyncJump(top_frame)) {
     // Not at an async operation.
+    if (error) {
+      *error = "Isolate must be paused at an async suspension point";
+    }
     return false;
   }
   Object& closure = Object::Handle(top_frame->GetAsyncOperation());
@@ -1313,24 +1343,42 @@
   Breakpoint* bpt = SetBreakpointAtActivation(Instance::Cast(closure), true);
   if (bpt == NULL) {
     // Unable to set the breakpoint.
+    if (error) {
+      *error = "Unable to set breakpoint at async suspension point";
+    }
     return false;
   }
   return true;
 }
 
 
-void Debugger::SetSingleStep() {
-  resume_action_ = kSingleStep;
-}
-
-
-void Debugger::SetStepOver() {
-  resume_action_ = kStepOver;
-}
-
-
-void Debugger::SetStepOut() {
-  resume_action_ = kStepOut;
+bool Debugger::SetResumeAction(ResumeAction action,
+                               intptr_t frame_index,
+                               const char** error) {
+  if (error) {
+    *error = NULL;
+  }
+  resume_frame_index_ = -1;
+  switch (action) {
+    case kStepInto:
+    case kStepOver:
+    case kStepOut:
+    case kContinue:
+      resume_action_ = action;
+      return true;
+    case kStepRewind:
+      if (!CanRewindFrame(frame_index, error)) {
+        return false;
+      }
+      resume_action_ = kStepRewind;
+      resume_frame_index_ = frame_index;
+      return true;
+    case kStepOverAsyncSuspension:
+      return SetupStepOverAsyncSuspension(error);
+    default:
+      UNREACHABLE();
+      return false;
+  }
 }
 
 
@@ -1622,6 +1670,7 @@
   ASSERT(stack_trace_ == NULL);
   stack_trace_ = stack_trace;
   Pause(&event);
+  HandleSteppingRequest(stack_trace_);  // we may get a rewind request
   stack_trace_ = NULL;
 }
 
@@ -2547,7 +2596,7 @@
 void Debugger::HandleSteppingRequest(DebuggerStackTrace* stack_trace,
                                      bool skip_next_step) {
   stepping_fp_ = 0;
-  if (resume_action_ == kSingleStep) {
+  if (resume_action_ == kStepInto) {
     // When single stepping, we need to deoptimize because we might be
     // stepping into optimized code.  This happens in particular if
     // the isolate has been interrupted, but can happen in other cases
@@ -2557,7 +2606,7 @@
     isolate_->set_single_step(true);
     skip_next_step_ = skip_next_step;
     if (FLAG_verbose_debug) {
-      OS::Print("HandleSteppingRequest- kSingleStep\n");
+      OS::Print("HandleSteppingRequest- kStepInto\n");
     }
   } else if (resume_action_ == kStepOver) {
     DeoptimizeWorld();
@@ -2582,6 +2631,244 @@
     if (FLAG_verbose_debug) {
       OS::Print("HandleSteppingRequest- kStepOut %" Px "\n", stepping_fp_);
     }
+  } else if (resume_action_ == kStepRewind) {
+    if (FLAG_trace_rewind) {
+      OS::PrintErr("Rewinding to frame %" Pd "\n", resume_frame_index_);
+      OS::PrintErr(
+          "-------------------------\n"
+          "All frames...\n\n");
+      StackFrameIterator iterator(false);
+      StackFrame* frame = iterator.NextFrame();
+      intptr_t num = 0;
+      while ((frame != NULL)) {
+        OS::PrintErr("#%04" Pd " %s\n", num++, frame->ToCString());
+        frame = iterator.NextFrame();
+      }
+    }
+    RewindToFrame(resume_frame_index_);
+    UNREACHABLE();
+  }
+}
+
+
+static intptr_t FindNextRewindFrameIndex(DebuggerStackTrace* stack,
+                                         intptr_t frame_index) {
+  for (intptr_t i = frame_index + 1; i < stack->Length(); i++) {
+    ActivationFrame* frame = stack->FrameAt(i);
+    if (frame->IsRewindable()) {
+      return i;
+    }
+  }
+  return -1;
+}
+
+
+// Can the top frame be rewound?
+bool Debugger::CanRewindFrame(intptr_t frame_index, const char** error) const {
+  // check rewind pc is found
+  DebuggerStackTrace* stack = Isolate::Current()->debugger()->StackTrace();
+  intptr_t num_frames = stack->Length();
+  if (frame_index < 1 || frame_index >= num_frames) {
+    if (error) {
+      *error = Thread::Current()->zone()->PrintToString(
+          "Frame must be in bounds [1..%" Pd
+          "]: "
+          "saw %" Pd "",
+          num_frames - 1, frame_index);
+    }
+    return false;
+  }
+  ActivationFrame* frame = stack->FrameAt(frame_index);
+  if (!frame->IsRewindable()) {
+    intptr_t next_index = FindNextRewindFrameIndex(stack, frame_index);
+    if (next_index > 0) {
+      *error = Thread::Current()->zone()->PrintToString(
+          "Cannot rewind to frame %" Pd
+          " due to conflicting compiler "
+          "optimizations. "
+          "Run the vm with --no-prune-dead-locals to disallow these "
+          "optimizations. "
+          "Next valid rewind frame is %" Pd ".",
+          frame_index, next_index);
+    } else {
+      *error = Thread::Current()->zone()->PrintToString(
+          "Cannot rewind to frame %" Pd
+          " due to conflicting compiler "
+          "optimizations. "
+          "Run the vm with --no-prune-dead-locals to disallow these "
+          "optimizations.",
+          frame_index);
+    }
+    return false;
+  }
+  return true;
+}
+
+
+// Given a return address pc, find the "rewind" pc, which is the pc
+// before the corresponding call.
+static uword LookupRewindPc(const Code& code, uword pc) {
+  ASSERT(!code.is_optimized());
+  ASSERT(code.ContainsInstructionAt(pc));
+
+  uword pc_offset = pc - code.PayloadStart();
+  const PcDescriptors& descriptors =
+      PcDescriptors::Handle(code.pc_descriptors());
+  PcDescriptors::Iterator iter(
+      descriptors, RawPcDescriptors::kRewind | RawPcDescriptors::kIcCall |
+                       RawPcDescriptors::kUnoptStaticCall);
+  intptr_t rewind_deopt_id = -1;
+  uword rewind_pc = 0;
+  while (iter.MoveNext()) {
+    if (iter.Kind() == RawPcDescriptors::kRewind) {
+      // Remember the last rewind so we don't need to iterator twice.
+      rewind_pc = code.PayloadStart() + iter.PcOffset();
+      rewind_deopt_id = iter.DeoptId();
+    }
+    if ((pc_offset == iter.PcOffset()) && (iter.DeoptId() == rewind_deopt_id)) {
+      return rewind_pc;
+    }
+  }
+  return 0;
+}
+
+
+void Debugger::RewindToFrame(intptr_t frame_index) {
+  Thread* thread = Thread::Current();
+  Zone* zone = thread->zone();
+  Code& code = Code::Handle(zone);
+  Function& function = Function::Handle(zone);
+
+  // Find the requested frame.
+  StackFrameIterator iterator(false);
+  intptr_t current_frame = 0;
+  for (StackFrame* frame = iterator.NextFrame(); frame != NULL;
+       frame = iterator.NextFrame()) {
+    ASSERT(frame->IsValid());
+    if (frame->IsDartFrame()) {
+      code = frame->LookupDartCode();
+      function = code.function();
+      if (!IsFunctionVisible(function)) {
+        continue;
+      }
+      if (code.is_optimized()) {
+        intptr_t sub_index = 0;
+        for (InlinedFunctionsIterator it(code, frame->pc()); !it.Done();
+             it.Advance()) {
+          if (current_frame == frame_index) {
+            RewindToOptimizedFrame(frame, code, sub_index);
+            UNREACHABLE();
+          }
+          current_frame++;
+          sub_index++;
+        }
+      } else {
+        if (current_frame == frame_index) {
+          // We are rewinding to an unoptimized frame.
+          RewindToUnoptimizedFrame(frame, code);
+          UNREACHABLE();
+        }
+        current_frame++;
+      }
+    }
+  }
+  UNIMPLEMENTED();
+}
+
+
+void Debugger::RewindToUnoptimizedFrame(StackFrame* frame, const Code& code) {
+  // We will be jumping out of the debugger rather than exiting this
+  // function, so prepare the debugger state.
+  stack_trace_ = NULL;
+  resume_action_ = kContinue;
+  resume_frame_index_ = -1;
+  EnterSingleStepMode();
+
+  uword rewind_pc = LookupRewindPc(code, frame->pc());
+  if (FLAG_trace_rewind && rewind_pc == 0) {
+    OS::PrintErr("Unable to find rewind pc for pc(%" Px ")\n", frame->pc());
+  }
+  ASSERT(rewind_pc != 0);
+  if (FLAG_trace_rewind) {
+    OS::PrintErr(
+        "===============================\n"
+        "Rewinding to unoptimized frame:\n"
+        "    rewind_pc(0x%" Px ") sp(0x%" Px ") fp(0x%" Px
+        ")\n"
+        "===============================\n",
+        rewind_pc, frame->sp(), frame->fp());
+  }
+  Exceptions::JumpToFrame(Thread::Current(), rewind_pc, frame->sp(),
+                          frame->fp(), true /* clear lazy deopt at target */);
+  UNREACHABLE();
+}
+
+
+void Debugger::RewindToOptimizedFrame(StackFrame* frame,
+                                      const Code& optimized_code,
+                                      intptr_t sub_index) {
+  post_deopt_frame_index_ = sub_index;
+
+  // We will be jumping out of the debugger rather than exiting this
+  // function, so prepare the debugger state.
+  stack_trace_ = NULL;
+  resume_action_ = kContinue;
+  resume_frame_index_ = -1;
+  EnterSingleStepMode();
+
+  if (FLAG_trace_rewind) {
+    OS::PrintErr(
+        "===============================\n"
+        "Deoptimizing frame for rewind:\n"
+        "    deopt_pc(0x%" Px ") sp(0x%" Px ") fp(0x%" Px
+        ")\n"
+        "===============================\n",
+        frame->pc(), frame->sp(), frame->fp());
+  }
+  Thread* thread = Thread::Current();
+  thread->set_resume_pc(frame->pc());
+  uword deopt_stub_pc = StubCode::DeoptForRewind_entry()->EntryPoint();
+  Exceptions::JumpToFrame(thread, deopt_stub_pc, frame->sp(), frame->fp(),
+                          true /* clear lazy deopt at target */);
+  UNREACHABLE();
+}
+
+
+void Debugger::RewindPostDeopt() {
+  intptr_t rewind_frame = post_deopt_frame_index_;
+  post_deopt_frame_index_ = -1;
+  if (FLAG_trace_rewind) {
+    OS::PrintErr("Post deopt, jumping to frame %" Pd "\n", rewind_frame);
+    OS::PrintErr(
+        "-------------------------\n"
+        "All frames...\n\n");
+    StackFrameIterator iterator(false);
+    StackFrame* frame = iterator.NextFrame();
+    intptr_t num = 0;
+    while ((frame != NULL)) {
+      OS::PrintErr("#%04" Pd " %s\n", num++, frame->ToCString());
+      frame = iterator.NextFrame();
+    }
+  }
+
+  Thread* thread = Thread::Current();
+  Zone* zone = thread->zone();
+  Code& code = Code::Handle(zone);
+
+  StackFrameIterator iterator(false);
+  intptr_t current_frame = 0;
+  for (StackFrame* frame = iterator.NextFrame(); frame != NULL;
+       frame = iterator.NextFrame()) {
+    ASSERT(frame->IsValid());
+    if (frame->IsDartFrame()) {
+      code = frame->LookupDartCode();
+      ASSERT(!code.is_optimized());
+      if (current_frame == rewind_frame) {
+        RewindToUnoptimizedFrame(frame, code);
+        UNREACHABLE();
+      }
+      current_frame++;
+    }
   }
 }
 
@@ -2793,7 +3080,7 @@
 
     // We are at the entry of an async function.
     // We issue a step over to resume at the point after the await statement.
-    SetStepOver();
+    SetResumeAction(kStepOver);
     // When we single step from a user breakpoint, our next stepping
     // point will be at the exact same pc.  Skip it.
     HandleSteppingRequest(stack_trace_, true /* skip next step */);
@@ -2846,7 +3133,7 @@
   // We are in the native call to Developer_debugger.  the developer
   // gets a better experience by not seeing this call. To accomplish
   // this, we continue execution until the call exits (step out).
-  SetStepOut();
+  SetResumeAction(kStepOut);
   HandleSteppingRequest(stack_trace_);
 
   stack_trace_ = NULL;
diff --git a/runtime/vm/debugger.h b/runtime/vm/debugger.h
index 7319c8e..74fd1ea 100644
--- a/runtime/vm/debugger.h
+++ b/runtime/vm/debugger.h
@@ -276,6 +276,9 @@
   // to the user and can be debugged.
   bool IsDebuggable() const;
 
+  // Returns true if it is possible to rewind the debugger to this frame.
+  bool IsRewindable() const;
+
   // The context level of a frame is the context level at the
   // PC/token index of the frame. It determines the depth of the context
   // chain that belongs to the function of this activation frame.
@@ -373,6 +376,15 @@
 
 class Debugger {
  public:
+  enum ResumeAction {
+    kContinue,
+    kStepInto,
+    kStepOver,
+    kStepOut,
+    kStepRewind,
+    kStepOverAsyncSuspension,
+  };
+
   typedef void EventHandler(ServiceEvent* event);
 
   Debugger();
@@ -412,11 +424,10 @@
   void RemoveBreakpoint(intptr_t bp_id);
   Breakpoint* GetBreakpointById(intptr_t id);
 
-  // Will return false if we are not at an await.
-  bool SetupStepOverAsyncSuspension();
-  void SetStepOver();
-  void SetSingleStep();
-  void SetStepOut();
+  bool SetResumeAction(ResumeAction action,
+                       intptr_t frame_index = 1,
+                       const char** error = NULL);
+
   bool IsStepping() const { return resume_action_ != kContinue; }
 
   bool IsPaused() const { return pause_event_ != NULL; }
@@ -513,11 +524,15 @@
 
   intptr_t limitBreakpointId() { return next_id_; }
 
- private:
-  enum ResumeAction { kContinue, kStepOver, kStepOut, kSingleStep };
+  // Callback to the debugger to continue frame rewind, post-deoptimization.
+  void RewindPostDeopt();
 
+ private:
   RawError* PauseRequest(ServiceEvent::EventKind kind);
 
+  // Will return false if we are not at an await.
+  bool SetupStepOverAsyncSuspension(const char** error);
+
   bool NeedsIsolateEvents();
   bool NeedsDebugEvents();
   void InvokeEventHandler(ServiceEvent* event);
@@ -588,6 +603,15 @@
   void HandleSteppingRequest(DebuggerStackTrace* stack_trace,
                              bool skip_next_step = false);
 
+  // Can we rewind to the indicated frame?
+  bool CanRewindFrame(intptr_t frame_index, const char** error) const;
+
+  void RewindToFrame(intptr_t frame_index);
+  void RewindToUnoptimizedFrame(StackFrame* frame, const Code& code);
+  void RewindToOptimizedFrame(StackFrame* frame,
+                              const Code& code,
+                              intptr_t post_deopt_frame_index);
+
   Isolate* isolate_;
   Dart_Port isolate_id_;  // A unique ID for the isolate in the debugger.
   bool initialized_;
@@ -601,6 +625,8 @@
 
   // Tells debugger what to do when resuming execution after a breakpoint.
   ResumeAction resume_action_;
+  intptr_t resume_frame_index_;
+  intptr_t post_deopt_frame_index_;
 
   // Do not call back to breakpoint handler if this flag is set.
   // Effectively this means ignoring breakpoints. Set when Dart code may
diff --git a/runtime/vm/debugger_api_impl.cc b/runtime/vm/debugger_api_impl.cc
index 71610d2..77b7b27 100644
--- a/runtime/vm/debugger_api_impl.cc
+++ b/runtime/vm/debugger_api_impl.cc
@@ -485,7 +485,7 @@
   DARTSCOPE(Thread::Current());
   Isolate* I = T->isolate();
   CHECK_DEBUGGER(I);
-  I->debugger()->SetStepOver();
+  I->debugger()->SetResumeAction(Debugger::kStepOver);
   return Api::Success();
 }
 
@@ -494,7 +494,7 @@
   DARTSCOPE(Thread::Current());
   Isolate* I = T->isolate();
   CHECK_DEBUGGER(I);
-  I->debugger()->SetSingleStep();
+  I->debugger()->SetResumeAction(Debugger::kStepInto);
   return Api::Success();
 }
 
@@ -503,7 +503,7 @@
   DARTSCOPE(Thread::Current());
   Isolate* I = T->isolate();
   CHECK_DEBUGGER(I);
-  I->debugger()->SetStepOut();
+  I->debugger()->SetResumeAction(Debugger::kStepOut);
   return Api::Success();
 }
 
diff --git a/runtime/vm/exceptions.cc b/runtime/vm/exceptions.cc
index 71eb55a..560de55 100644
--- a/runtime/vm/exceptions.cc
+++ b/runtime/vm/exceptions.cc
@@ -189,7 +189,6 @@
 static void FindErrorHandler(uword* handler_pc,
                              uword* handler_sp,
                              uword* handler_fp) {
-  // TODO(turnidge): Is there a faster way to get the next entry frame?
   StackFrameIterator frames(StackFrameIterator::kDontValidateFrames);
   StackFrame* frame = frames.NextFrame();
   ASSERT(frame != NULL);
@@ -228,7 +227,17 @@
         break;
       }
     }
+  }
+#endif  // !DBC
+  return program_counter;
+}
 
+
+static void ClearLazyDeopts(Thread* thread, uword frame_pointer) {
+#if !defined(TARGET_ARCH_DBC)
+  MallocGrowableArray<PendingLazyDeopt>* pending_deopts =
+      thread->isolate()->pending_deopts();
+  if (pending_deopts->length() > 0) {
     // We may be jumping over frames scheduled for lazy deopt. Remove these
     // frames from the pending deopt table, but only after unmarking them so
     // any stack walk that happens before the stack is unwound will still work.
@@ -264,7 +273,6 @@
 #endif
   }
 #endif  // !DBC
-  return program_counter;
 }
 
 
@@ -281,14 +289,18 @@
   thread->set_resume_pc(remapped_pc);
   uword run_exception_pc = StubCode::RunExceptionHandler_entry()->EntryPoint();
   Exceptions::JumpToFrame(thread, run_exception_pc, stack_pointer,
-                          frame_pointer);
+                          frame_pointer, false /* do not clear deopt */);
 }
 
 
 void Exceptions::JumpToFrame(Thread* thread,
                              uword program_counter,
                              uword stack_pointer,
-                             uword frame_pointer) {
+                             uword frame_pointer,
+                             bool clear_deopt_at_target) {
+  uword fp_for_clearing =
+      (clear_deopt_at_target ? frame_pointer + 1 : frame_pointer);
+  ClearLazyDeopts(thread, fp_for_clearing);
 #if defined(USING_SIMULATOR)
   // Unwinding of the C++ frames and destroying of their stack resources is done
   // by the simulator, because the target stack_pointer is a simulated stack
diff --git a/runtime/vm/exceptions.h b/runtime/vm/exceptions.h
index c3fc408..2b6fd75 100644
--- a/runtime/vm/exceptions.h
+++ b/runtime/vm/exceptions.h
@@ -83,7 +83,8 @@
   static void JumpToFrame(Thread* thread,
                           uword program_counter,
                           uword stack_pointer,
-                          uword frame_pointer);
+                          uword frame_pointer,
+                          bool clear_deopt_at_target);
 
  private:
   DISALLOW_COPY_AND_ASSIGN(Exceptions);
diff --git a/runtime/vm/flow_graph_compiler.cc b/runtime/vm/flow_graph_compiler.cc
index c6b6663..405b37f 100644
--- a/runtime/vm/flow_graph_compiler.cc
+++ b/runtime/vm/flow_graph_compiler.cc
@@ -1271,6 +1271,7 @@
                                    kNumArgsChecked)
               ->raw();
     }
+    AddCurrentDescriptor(RawPcDescriptors::kRewind, deopt_id, token_pos);
     EmitUnoptimizedStaticCall(argument_count, deopt_id, token_pos, locs,
                               call_ic_data);
   }
diff --git a/runtime/vm/intermediate_language.cc b/runtime/vm/intermediate_language.cc
index 49126f9..373aa48 100644
--- a/runtime/vm/intermediate_language.cc
+++ b/runtime/vm/intermediate_language.cc
@@ -3075,6 +3075,8 @@
   } else {
     // Unoptimized code.
     ASSERT(!HasICData());
+    compiler->AddCurrentDescriptor(RawPcDescriptors::kRewind, deopt_id(),
+                                   token_pos());
     bool is_smi_two_args_op = false;
     const StubEntry* stub_entry = TwoArgsSmiOpInlineCacheEntry(token_kind());
     if (stub_entry != NULL) {
diff --git a/runtime/vm/json_stream.cc b/runtime/vm/json_stream.cc
index 8310e70..e75ba30 100644
--- a/runtime/vm/json_stream.cc
+++ b/runtime/vm/json_stream.cc
@@ -139,6 +139,8 @@
       return "Isolate must be runnable";
     case kIsolateMustBePaused:
       return "Isolate must be paused";
+    case kCannotResume:
+      return "Cannot resume execution";
     case kIsolateIsReloading:
       return "Isolate is reloading";
     case kFileSystemAlreadyExists:
diff --git a/runtime/vm/json_stream.h b/runtime/vm/json_stream.h
index b54bfb2..bdf1b3a 100644
--- a/runtime/vm/json_stream.h
+++ b/runtime/vm/json_stream.h
@@ -53,6 +53,7 @@
   kStreamNotSubscribed = 104,
   kIsolateMustBeRunnable = 105,
   kIsolateMustBePaused = 106,
+  kCannotResume = 107,
 
   // Experimental (used in private rpcs).
   kIsolateIsReloading = 1000,
diff --git a/runtime/vm/kernel_reader.cc b/runtime/vm/kernel_reader.cc
index e3b633f..d11e931 100644
--- a/runtime/vm/kernel_reader.cc
+++ b/runtime/vm/kernel_reader.cc
@@ -104,7 +104,7 @@
                        &active_class_,
                        /*finalize=*/false) {
   intptr_t source_file_count = program_->line_starting_table().size();
-  scripts_ = Array::New(source_file_count);
+  scripts_ = Array::New(source_file_count, Heap::kOld);
 }
 
 Object& KernelReader::ReadProgram() {
@@ -265,7 +265,7 @@
   // Build implemented interface types
   intptr_t interface_count = kernel_klass->implemented_classes().length();
   const dart::Array& interfaces =
-      dart::Array::Handle(Z, dart::Array::New(interface_count));
+      dart::Array::Handle(Z, dart::Array::New(interface_count, Heap::kOld));
   for (intptr_t i = 0; i < interface_count; i++) {
     InterfaceType* kernel_interface_type =
         kernel_klass->implemented_classes()[i];
@@ -435,13 +435,13 @@
   script ^= scripts_.At(source_uri_index);
   if (script.IsNull()) {
     String* uri = program_->source_uri_table().strings()[source_uri_index];
-    script = Script::New(H.DartString(uri), dart::String::ZoneHandle(Z),
-                         RawScript::kKernelTag);
+    script = Script::New(H.DartString(uri, Heap::kOld),
+                         dart::String::ZoneHandle(Z), RawScript::kKernelTag);
     scripts_.SetAt(source_uri_index, script);
     intptr_t* line_starts =
         program_->line_starting_table().valuesFor(source_uri_index);
     intptr_t line_count = line_starts[0];
-    Array& array_object = Array::Handle(Z, Array::New(line_count));
+    Array& array_object = Array::Handle(Z, Array::New(line_count, Heap::kOld));
     Smi& value = Smi::Handle(Z);
     for (intptr_t i = 0; i < line_count; ++i) {
       value = Smi::New(line_starts[i + 1]);
diff --git a/runtime/vm/kernel_to_il.cc b/runtime/vm/kernel_to_il.cc
index f741ce5..8078bca 100644
--- a/runtime/vm/kernel_to_il.cc
+++ b/runtime/vm/kernel_to_il.cc
@@ -1273,7 +1273,7 @@
   if (named->length() == 0) return Array::ZoneHandle(Z);
 
   const Array& names =
-      Array::ZoneHandle(Z, Array::New(named->length(), allocation_space_));
+      Array::ZoneHandle(Z, Array::New(named->length(), Heap::kOld));
   for (intptr_t i = 0; i < named->length(); ++i) {
     names.SetAt(i, DartSymbol((*named)[i]->name()));
   }
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index ac586d9..ba60399 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -11700,6 +11700,8 @@
       return "runtime-call ";
     case RawPcDescriptors::kOsrEntry:
       return "osr-entry    ";
+    case RawPcDescriptors::kRewind:
+      return "rewind       ";
     case RawPcDescriptors::kOther:
       return "other        ";
     case RawPcDescriptors::kAnyKind:
diff --git a/runtime/vm/parser.cc b/runtime/vm/parser.cc
index 1a91fcb..d3b62f6 100644
--- a/runtime/vm/parser.cc
+++ b/runtime/vm/parser.cc
@@ -44,7 +44,6 @@
 
 DEFINE_FLAG(bool, enable_debug_break, false, "Allow use of break \"message\".");
 DEFINE_FLAG(bool, trace_parser, false, "Trace parser operations.");
-DEFINE_FLAG(bool, warn_mixin_typedef, true, "Warning on legacy mixin typedef.");
 DEFINE_FLAG(bool, warn_new_tearoff_syntax, true, "Warning on new tear off.");
 // TODO(floitsch): remove the conditional-directive flag, once we publicly
 // committed to the current version.
@@ -5073,23 +5072,6 @@
 }
 
 
-// Look ahead to detect if we are seeing ident [ TypeParameters ] "=".
-// Token position remains unchanged.
-bool Parser::IsMixinAppAlias() {
-  if (IsIdentifier() && (LookaheadToken(1) == Token::kASSIGN)) {
-    return true;
-  }
-  const TokenPosScope saved_pos(this);
-  if (IsIdentifier() && (LookaheadToken(1) == Token::kLT)) {
-    ConsumeToken();
-    if (TryParseTypeParameters() && (CurrentToken() == Token::kASSIGN)) {
-      return true;
-    }
-  }
-  return false;
-}
-
-
 void Parser::ParseTypedef(const GrowableObjectArray& pending_classes,
                           const Object& tl_owner,
                           TokenPosition metadata_pos) {
@@ -5098,14 +5080,6 @@
       metadata_pos.IsReal() ? metadata_pos : TokenPos();
   ExpectToken(Token::kTYPEDEF);
 
-  if (IsMixinAppAlias()) {
-    if (FLAG_warn_mixin_typedef) {
-      ReportWarning(TokenPos(), "deprecated mixin application typedef");
-    }
-    ParseMixinAppAlias(pending_classes, tl_owner, metadata_pos);
-    return;
-  }
-
   // Parse the result type of the function type.
   AbstractType& result_type = Type::Handle(Z, Type::DynamicType());
   if (CurrentToken() == Token::kVOID) {
diff --git a/runtime/vm/parser.h b/runtime/vm/parser.h
index 004913e..54a6027 100644
--- a/runtime/vm/parser.h
+++ b/runtime/vm/parser.h
@@ -750,7 +750,6 @@
   bool IsSymbol(const String& symbol);
   bool IsSimpleLiteral(const AbstractType& type, Instance* value);
   bool IsFunctionTypeAliasName();
-  bool IsMixinAppAlias();
   bool TryParseQualIdent();
   bool TryParseTypeParameters();
   bool TryParseTypeArguments();
diff --git a/runtime/vm/precompiler.cc b/runtime/vm/precompiler.cc
index 8d72d929a..ce07486 100644
--- a/runtime/vm/precompiler.cc
+++ b/runtime/vm/precompiler.cc
@@ -841,31 +841,28 @@
     if (pool.InfoAt(i) == ObjectPool::kTaggedObject) {
       entry = pool.ObjectAt(i);
       if (entry.IsICData()) {
+        // A dynamic call.
         call_site ^= entry.raw();
-        for (intptr_t j = 0; j < call_site.NumberOfChecks(); j++) {
-          target = call_site.GetTargetAt(j);
-          AddFunction(target);
-          if (!target.is_static()) {
-            // Super call (should not enqueue selector) or dynamic call with a
-            // CHA prediction (should enqueue selector).
-            selector = call_site.target_name();
-            AddSelector(selector);
-          }
-        }
-        if (call_site.NumberOfChecks() == 0) {
-          // A dynamic call.
-          selector = call_site.target_name();
-          AddSelector(selector);
-          if (selector.raw() == Symbols::Call().raw()) {
-            // Potential closure call.
-            AddClosureCall(call_site);
-          }
+        ASSERT(!call_site.is_static_call());
+        selector = call_site.target_name();
+        AddSelector(selector);
+        if (selector.raw() == Symbols::Call().raw()) {
+          // Potential closure call.
+          const Array& arguments_descriptor =
+              Array::Handle(Z, call_site.arguments_descriptor());
+          AddClosureCall(arguments_descriptor);
         }
       } else if (entry.IsMegamorphicCache()) {
         // A dynamic call.
         cache ^= entry.raw();
         selector = cache.target_name();
         AddSelector(selector);
+        if (selector.raw() == Symbols::Call().raw()) {
+          // Potential closure call.
+          const Array& arguments_descriptor =
+              Array::Handle(Z, cache.arguments_descriptor());
+          AddClosureCall(arguments_descriptor);
+        }
       } else if (entry.IsField()) {
         // Potential need for field initializer.
         field ^= entry.raw();
@@ -1068,9 +1065,7 @@
 }
 
 
-void Precompiler::AddClosureCall(const ICData& call_site) {
-  const Array& arguments_descriptor =
-      Array::Handle(Z, call_site.arguments_descriptor());
+void Precompiler::AddClosureCall(const Array& arguments_descriptor) {
   const Class& cache_class =
       Class::Handle(Z, I->object_store()->closure_class());
   const Function& dispatcher = Function::Handle(
diff --git a/runtime/vm/precompiler.h b/runtime/vm/precompiler.h
index 2566a78..9f2ca90 100644
--- a/runtime/vm/precompiler.h
+++ b/runtime/vm/precompiler.h
@@ -368,7 +368,7 @@
   void AddTypeArguments(const TypeArguments& args);
   void AddCalleesOf(const Function& function);
   void AddConstObject(const Instance& instance);
-  void AddClosureCall(const ICData& call_site);
+  void AddClosureCall(const Array& arguments_descriptor);
   void AddField(const Field& field);
   void AddFunction(const Function& function);
   void AddInstantiatedClass(const Class& cls);
diff --git a/runtime/vm/raw_object.h b/runtime/vm/raw_object.h
index 253c304..532cb72 100644
--- a/runtime/vm/raw_object.h
+++ b/runtime/vm/raw_object.h
@@ -1202,7 +1202,8 @@
     kUnoptStaticCall = kIcCall << 1,       // Call to a known target via stub.
     kRuntimeCall = kUnoptStaticCall << 1,  // Runtime call.
     kOsrEntry = kRuntimeCall << 1,         // OSR entry point in unopt. code.
-    kOther = kOsrEntry << 1,
+    kRewind = kOsrEntry << 1,              // Call rewind target address.
+    kOther = kRewind << 1,
     kLastKind = kOther,
     kAnyKind = -1
   };
diff --git a/runtime/vm/runtime_entry_list.h b/runtime/vm/runtime_entry_list.h
index d450ee4..edc0e41 100644
--- a/runtime/vm/runtime_entry_list.h
+++ b/runtime/vm/runtime_entry_list.h
@@ -40,6 +40,7 @@
   V(TraceFunctionEntry)                                                        \
   V(TraceFunctionExit)                                                         \
   V(DeoptimizeMaterialize)                                                     \
+  V(RewindPostDeopt)                                                           \
   V(UpdateFieldCid)                                                            \
   V(InitStaticField)                                                           \
   V(GrowRegExpStack)                                                           \
diff --git a/runtime/vm/service.cc b/runtime/vm/service.cc
index 259b2c0..dce3eac 100644
--- a/runtime/vm/service.cc
+++ b/runtime/vm/service.cc
@@ -2988,18 +2988,57 @@
 }
 
 
+static const char* const step_enum_names[] = {
+    "None", "Into", "Over", "Out", "Rewind", "OverAsyncSuspension", NULL,
+};
+
+
+static const Debugger::ResumeAction step_enum_values[] = {
+    Debugger::kContinue,   Debugger::kStepInto,
+    Debugger::kStepOver,   Debugger::kStepOut,
+    Debugger::kStepRewind, Debugger::kStepOverAsyncSuspension,
+    Debugger::kContinue,  // Default value
+};
+
+
 static const MethodParameter* resume_params[] = {
-    RUNNABLE_ISOLATE_PARAMETER, NULL,
+    RUNNABLE_ISOLATE_PARAMETER,
+    new EnumParameter("step", false, step_enum_names),
+    new UIntParameter("frameIndex", false), NULL,
 };
 
 
 static bool Resume(Thread* thread, JSONStream* js) {
   const char* step_param = js->LookupParam("step");
+  Debugger::ResumeAction step = Debugger::kContinue;
+  if (step_param != NULL) {
+    step = EnumMapper(step_param, step_enum_names, step_enum_values);
+  }
+#if defined(TARGET_ARCH_DBC)
+  if (step == Debugger::kStepRewind) {
+    js->PrintError(kCannotResume,
+                   "Rewind not yet implemented on this architecture");
+    return true;
+  }
+#endif
+  intptr_t frame_index = 1;
+  const char* frame_index_param = js->LookupParam("frameIndex");
+  if (frame_index_param != NULL) {
+    if (step != Debugger::kStepRewind) {
+      // Only rewind supports the frameIndex parameter.
+      js->PrintError(
+          kInvalidParams,
+          "%s: the 'frameIndex' parameter can only be used when rewinding",
+          js->method());
+      return true;
+    }
+    frame_index = UIntParameter::Parse(js->LookupParam("frameIndex"));
+  }
   Isolate* isolate = thread->isolate();
   if (isolate->message_handler()->is_paused_on_start()) {
     // If the user is issuing a 'Over' or an 'Out' step, that is the
     // same as a regular resume request.
-    if ((step_param != NULL) && (strcmp(step_param, "Into") == 0)) {
+    if (step == Debugger::kStepInto) {
       isolate->debugger()->EnterSingleStepMode();
     }
     isolate->message_handler()->set_should_pause_on_start(false);
@@ -3028,31 +3067,18 @@
     PrintSuccess(js);
     return true;
   }
-  if (isolate->debugger()->PauseEvent() != NULL) {
-    if (step_param != NULL) {
-      if (strcmp(step_param, "Into") == 0) {
-        isolate->debugger()->SetSingleStep();
-      } else if (strcmp(step_param, "Over") == 0) {
-        isolate->debugger()->SetStepOver();
-      } else if (strcmp(step_param, "Out") == 0) {
-        isolate->debugger()->SetStepOut();
-      } else if (strcmp(step_param, "OverAsyncSuspension") == 0) {
-        if (!isolate->debugger()->SetupStepOverAsyncSuspension()) {
-          js->PrintError(kInvalidParams,
-                         "Isolate must be paused at an async suspension point");
-          return true;
-        }
-      } else {
-        PrintInvalidParamError(js, "step");
-        return true;
-      }
-    }
-    isolate->SetResumeRequest();
-    PrintSuccess(js);
+  if (isolate->debugger()->PauseEvent() == NULL) {
+    js->PrintError(kIsolateMustBePaused, NULL);
     return true;
   }
 
-  js->PrintError(kIsolateMustBePaused, NULL);
+  const char* error = NULL;
+  if (!isolate->debugger()->SetResumeAction(step, frame_index, &error)) {
+    js->PrintError(kCannotResume, error);
+    return true;
+  }
+  isolate->SetResumeRequest();
+  PrintSuccess(js);
   return true;
 }
 
diff --git a/runtime/vm/simulator_dbc.cc b/runtime/vm/simulator_dbc.cc
index 8febf13..98049f4 100644
--- a/runtime/vm/simulator_dbc.cc
+++ b/runtime/vm/simulator_dbc.cc
@@ -3498,15 +3498,17 @@
 
   {
     BYTECODE(LoadIndexedUint32, A_B_C);
-    uint8_t* data = SimulatorHelpers::GetTypedData(FP[rB], FP[rC]);
-    FP[rA] = reinterpret_cast<RawObject*>(*reinterpret_cast<uintptr_t*>(data));
+    const uint8_t* data = SimulatorHelpers::GetTypedData(FP[rB], FP[rC]);
+    const uint32_t value = *reinterpret_cast<const uint32_t*>(data);
+    FP[rA] = reinterpret_cast<RawObject*>(value);
     DISPATCH();
   }
 
   {
     BYTECODE(LoadIndexedInt32, A_B_C);
-    uint8_t* data = SimulatorHelpers::GetTypedData(FP[rB], FP[rC]);
-    FP[rA] = reinterpret_cast<RawObject*>(*reinterpret_cast<intptr_t*>(data));
+    const uint8_t* data = SimulatorHelpers::GetTypedData(FP[rB], FP[rC]);
+    const int32_t value = *reinterpret_cast<const int32_t*>(data);
+    FP[rA] = reinterpret_cast<RawObject*>(value);
     DISPATCH();
   }
 
@@ -3715,14 +3717,25 @@
   fp_ = reinterpret_cast<RawObject**>(fp);
 
   if (pc == StubCode::RunExceptionHandler_entry()->EntryPoint()) {
-    // Instead of executing the RunException stub, we implement its
-    // behavior here.
+    // The RunExceptionHandler stub is a placeholder.  We implement
+    // its behavior here.
     RawObject* raw_exception = thread->active_exception();
     RawObject* raw_stacktrace = thread->active_stacktrace();
     ASSERT(raw_exception != Object::null());
     special_[kExceptionSpecialIndex] = raw_exception;
     special_[kStacktraceSpecialIndex] = raw_stacktrace;
     pc_ = thread->resume_pc();
+  } else if (pc == StubCode::DeoptForRewind_entry()->EntryPoint()) {
+    // The DeoptForRewind stub is a placeholder.  We will eventually
+    // implement its behavior here.
+    //
+    // TODO(turnidge): Refactor the Deopt bytecode so that we can use
+    // the implementation here too.  The deopt pc is stored in
+    // Thread::resume_pc().  After invoking deoptimization, we usually
+    // call into Debugger::RewindPostDeopt(), but I need to figure out
+    // if that makes any sense (it would JumpToFrame during a
+    // JumpToFrame, which seems wrong).
+    UNIMPLEMENTED();
   } else {
     pc_ = pc;
   }
diff --git a/runtime/vm/stub_code.h b/runtime/vm/stub_code.h
index 3a2cea0..35d589d 100644
--- a/runtime/vm/stub_code.h
+++ b/runtime/vm/stub_code.h
@@ -27,6 +27,7 @@
   V(GetStackPointer)                                                           \
   V(JumpToFrame)                                                               \
   V(RunExceptionHandler)                                                       \
+  V(DeoptForRewind)                                                            \
   V(UpdateStoreBuffer)                                                         \
   V(PrintStopMessage)                                                          \
   V(CallToRuntime)                                                             \
@@ -75,6 +76,7 @@
   V(LazyCompile)                                                               \
   V(OptimizeFunction)                                                          \
   V(RunExceptionHandler)                                                       \
+  V(DeoptForRewind)                                                            \
   V(FixCallersTarget)                                                          \
   V(Deoptimize)                                                                \
   V(DeoptimizeLazyFromReturn)                                                  \
@@ -195,6 +197,12 @@
 
 enum DeoptStubKind { kLazyDeoptFromReturn, kLazyDeoptFromThrow, kEagerDeopt };
 
+// Zap value used to indicate unused CODE_REG in deopt.
+static const uword kZapCodeReg = 0xf1f1f1f1;
+
+// Zap value used to indicate unused return address in deopt.
+static const uword kZapReturnAddress = 0xe1e1e1e1;
+
 }  // namespace dart
 
 #endif  // RUNTIME_VM_STUB_CODE_H_
diff --git a/runtime/vm/stub_code_arm.cc b/runtime/vm/stub_code_arm.cc
index 87b054d..58124b2 100644
--- a/runtime/vm/stub_code_arm.cc
+++ b/runtime/vm/stub_code_arm.cc
@@ -537,19 +537,20 @@
   __ LeaveStubFrame();
   // Remove materialization arguments.
   __ add(SP, SP, Operand(R2, ASR, kSmiTagSize));
-  __ Ret();
+  // The caller is responsible for emitting the return instruction.
 }
 
 
 // R0: result, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromReturnStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ LoadImmediate(IP, 0xf1f1f1f1);
+  __ LoadImmediate(IP, kZapCodeReg);
   __ Push(IP);
   // Return address for "call" to deopt stub.
-  __ LoadImmediate(LR, 0xe1e1e1e1);
+  __ LoadImmediate(LR, kZapReturnAddress);
   __ ldr(CODE_REG, Address(THR, Thread::lazy_deopt_from_return_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromReturn);
+  __ Ret();
 }
 
 
@@ -557,17 +558,19 @@
 // R1: stacktrace, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromThrowStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ LoadImmediate(IP, 0xf1f1f1f1);
+  __ LoadImmediate(IP, kZapCodeReg);
   __ Push(IP);
   // Return address for "call" to deopt stub.
-  __ LoadImmediate(LR, 0xe1e1e1e1);
+  __ LoadImmediate(LR, kZapReturnAddress);
   __ ldr(CODE_REG, Address(THR, Thread::lazy_deopt_from_throw_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromThrow);
+  __ Ret();
 }
 
 
 void StubCode::GenerateDeoptimizeStub(Assembler* assembler) {
   GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+  __ Ret();
 }
 
 
@@ -1899,6 +1902,26 @@
 }
 
 
+// Deoptimize a frame on the call stack before rewinding.
+// The arguments are stored in the Thread object.
+// No result.
+void StubCode::GenerateDeoptForRewindStub(Assembler* assembler) {
+  // Push zap value instead of CODE_REG.
+  __ LoadImmediate(IP, kZapCodeReg);
+  __ Push(IP);
+
+  // Load the deopt pc into LR.
+  __ LoadFromOffset(kWord, LR, THR, Thread::resume_pc_offset());
+  GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+
+  // After we have deoptimized, jump to the correct frame.
+  __ EnterStubFrame();
+  __ CallRuntime(kRewindPostDeoptRuntimeEntry, 0);
+  __ LeaveStubFrame();
+  __ bkpt(0);
+}
+
+
 // Calls to the runtime to optimize the given function.
 // R8: function to be reoptimized.
 // R4: argument descriptor (preserved).
diff --git a/runtime/vm/stub_code_arm64.cc b/runtime/vm/stub_code_arm64.cc
index 5a5a156..385e703 100644
--- a/runtime/vm/stub_code_arm64.cc
+++ b/runtime/vm/stub_code_arm64.cc
@@ -558,19 +558,20 @@
   __ LeaveStubFrame();
   // Remove materialization arguments.
   __ add(SP, SP, Operand(R2));
-  __ ret();
+  // The caller is responsible for emitting the return instruction.
 }
 
 
 // R0: result, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromReturnStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ LoadImmediate(TMP, 0xf1f1f1f1);
+  __ LoadImmediate(TMP, kZapCodeReg);
   __ Push(TMP);
   // Return address for "call" to deopt stub.
-  __ LoadImmediate(LR, 0xe1e1e1e1);
+  __ LoadImmediate(LR, kZapReturnAddress);
   __ ldr(CODE_REG, Address(THR, Thread::lazy_deopt_from_return_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromReturn);
+  __ ret();
 }
 
 
@@ -578,17 +579,19 @@
 // R1: stacktrace, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromThrowStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ LoadImmediate(TMP, 0xf1f1f1f1);
+  __ LoadImmediate(TMP, kZapCodeReg);
   __ Push(TMP);
   // Return address for "call" to deopt stub.
-  __ LoadImmediate(LR, 0xe1e1e1e1);
+  __ LoadImmediate(LR, kZapReturnAddress);
   __ ldr(CODE_REG, Address(THR, Thread::lazy_deopt_from_throw_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromThrow);
+  __ ret();
 }
 
 
 void StubCode::GenerateDeoptimizeStub(Assembler* assembler) {
   GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+  __ ret();
 }
 
 
@@ -1949,6 +1952,26 @@
 }
 
 
+// Deoptimize a frame on the call stack before rewinding.
+// The arguments are stored in the Thread object.
+// No result.
+void StubCode::GenerateDeoptForRewindStub(Assembler* assembler) {
+  // Push zap value instead of CODE_REG.
+  __ LoadImmediate(TMP, kZapCodeReg);
+  __ Push(TMP);
+
+  // Load the deopt pc into LR.
+  __ LoadFromOffset(LR, THR, Thread::resume_pc_offset());
+  GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+
+  // After we have deoptimized, jump to the correct frame.
+  __ EnterStubFrame();
+  __ CallRuntime(kRewindPostDeoptRuntimeEntry, 0);
+  __ LeaveStubFrame();
+  __ brk(0);
+}
+
+
 // Calls to the runtime to optimize the given function.
 // R6: function to be re-optimized.
 // R4: argument descriptor (preserved).
diff --git a/runtime/vm/stub_code_dbc.cc b/runtime/vm/stub_code_dbc.cc
index da24e19..ef41182 100644
--- a/runtime/vm/stub_code_dbc.cc
+++ b/runtime/vm/stub_code_dbc.cc
@@ -47,6 +47,12 @@
 }
 
 
+// Not executed, but used as a sentinel in Simulator::JumpToFrame.
+void StubCode::GenerateDeoptForRewindStub(Assembler* assembler) {
+  __ Trap();
+}
+
+
 // TODO(vegorov) Don't generate this stub.
 void StubCode::GenerateFixCallersTargetStub(Assembler* assembler) {
   __ Trap();
diff --git a/runtime/vm/stub_code_ia32.cc b/runtime/vm/stub_code_ia32.cc
index ca70617..ce6521d 100644
--- a/runtime/vm/stub_code_ia32.cc
+++ b/runtime/vm/stub_code_ia32.cc
@@ -351,8 +351,6 @@
 //   +------------------+
 //   | return-address   |  (deoptimization point)
 //   +------------------+
-//   | Saved CODE_REG   |
-//   +------------------+
 //   | ...              | <- SP of optimized frame
 //
 // Parts of the code cannot GC, part of the code can GC.
@@ -462,15 +460,16 @@
   __ popl(ECX);       // Pop return address.
   __ addl(ESP, EBX);  // Remove materialization arguments.
   __ pushl(ECX);      // Push return address.
-  __ ret();
+  // The caller is responsible for emitting the return instruction.
 }
 
 
 // EAX: result, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromReturnStub(Assembler* assembler) {
   // Return address for "call" to deopt stub.
-  __ pushl(Immediate(0xe1e1e1e1));
+  __ pushl(Immediate(kZapReturnAddress));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromReturn);
+  __ ret();
 }
 
 
@@ -478,13 +477,15 @@
 // EDX: stacktrace, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromThrowStub(Assembler* assembler) {
   // Return address for "call" to deopt stub.
-  __ pushl(Immediate(0xe1e1e1e1));
+  __ pushl(Immediate(kZapReturnAddress));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromThrow);
+  __ ret();
 }
 
 
 void StubCode::GenerateDeoptimizeStub(Assembler* assembler) {
   GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+  __ ret();
 }
 
 
@@ -1835,6 +1836,22 @@
 }
 
 
+// Deoptimize a frame on the call stack before rewinding.
+// The arguments are stored in the Thread object.
+// No result.
+void StubCode::GenerateDeoptForRewindStub(Assembler* assembler) {
+  // Push the deopt pc.
+  __ pushl(Address(THR, Thread::resume_pc_offset()));
+  GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+
+  // After we have deoptimized, jump to the correct frame.
+  __ EnterStubFrame();
+  __ CallRuntime(kRewindPostDeoptRuntimeEntry, 0);
+  __ LeaveFrame();
+  __ int3();
+}
+
+
 // Calls to the runtime to optimize the given function.
 // EBX: function to be reoptimized.
 // EDX: argument descriptor (preserved).
diff --git a/runtime/vm/stub_code_mips.cc b/runtime/vm/stub_code_mips.cc
index d52e6cc..53394cf 100644
--- a/runtime/vm/stub_code_mips.cc
+++ b/runtime/vm/stub_code_mips.cc
@@ -549,18 +549,19 @@
   // Remove materialization arguments.
   __ SmiUntag(T1);
   __ addu(SP, SP, T1);
-  __ Ret();
+  // The caller is responsible for emitting the return instruction.
 }
 
 // V0: result, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromReturnStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ LoadImmediate(TMP, 0xf1f1f1f1);
+  __ LoadImmediate(TMP, kZapCodeReg);
   __ Push(TMP);
   // Return address for "call" to deopt stub.
-  __ LoadImmediate(RA, 0xe1e1e1e1);
+  __ LoadImmediate(RA, kZapReturnAddress);
   __ lw(CODE_REG, Address(THR, Thread::lazy_deopt_from_return_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromReturn);
+  __ Ret();
 }
 
 
@@ -568,17 +569,19 @@
 // V1: stacktrace, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromThrowStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ LoadImmediate(TMP, 0xf1f1f1f1);
+  __ LoadImmediate(TMP, kZapCodeReg);
   __ Push(TMP);
   // Return address for "call" to deopt stub.
-  __ LoadImmediate(RA, 0xe1e1e1e1);
+  __ LoadImmediate(RA, kZapReturnAddress);
   __ lw(CODE_REG, Address(THR, Thread::lazy_deopt_from_throw_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromThrow);
+  __ Ret();
 }
 
 
 void StubCode::GenerateDeoptimizeStub(Assembler* assembler) {
   GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+  __ Ret();
 }
 
 
@@ -2028,6 +2031,26 @@
 }
 
 
+// Deoptimize a frame on the call stack before rewinding.
+// The arguments are stored in the Thread object.
+// No result.
+void StubCode::GenerateDeoptForRewindStub(Assembler* assembler) {
+  // Push zap value instead of CODE_REG.
+  __ LoadImmediate(TMP, kZapCodeReg);
+  __ Push(TMP);
+
+  // Load the deopt pc into RA.
+  __ lw(RA, Address(THR, Thread::resume_pc_offset()));
+  GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+
+  // After we have deoptimized, jump to the correct frame.
+  __ EnterStubFrame();
+  __ CallRuntime(kRewindPostDeoptRuntimeEntry, 0);
+  __ LeaveStubFrame();
+  __ break_(0);
+}
+
+
 // Calls to the runtime to optimize the given function.
 // T0: function to be reoptimized.
 // S4: argument descriptor (preserved).
diff --git a/runtime/vm/stub_code_x64.cc b/runtime/vm/stub_code_x64.cc
index 167154b..0341f26 100644
--- a/runtime/vm/stub_code_x64.cc
+++ b/runtime/vm/stub_code_x64.cc
@@ -498,18 +498,19 @@
   __ popq(RCX);       // Pop return address.
   __ addq(RSP, RBX);  // Remove materialization arguments.
   __ pushq(RCX);      // Push return address.
-  __ ret();
+  // The caller is responsible for emitting the return instruction.
 }
 
 
 // RAX: result, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromReturnStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ pushq(Immediate(0xf1f1f1f1));
+  __ pushq(Immediate(kZapCodeReg));
   // Return address for "call" to deopt stub.
-  __ pushq(Immediate(0xe1e1e1e1));
+  __ pushq(Immediate(kZapReturnAddress));
   __ movq(CODE_REG, Address(THR, Thread::lazy_deopt_from_return_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromReturn);
+  __ ret();
 }
 
 
@@ -517,16 +518,18 @@
 // RDX: stacktrace, must be preserved
 void StubCode::GenerateDeoptimizeLazyFromThrowStub(Assembler* assembler) {
   // Push zap value instead of CODE_REG for lazy deopt.
-  __ pushq(Immediate(0xf1f1f1f1));
+  __ pushq(Immediate(kZapCodeReg));
   // Return address for "call" to deopt stub.
-  __ pushq(Immediate(0xe1e1e1e1));
+  __ pushq(Immediate(kZapReturnAddress));
   __ movq(CODE_REG, Address(THR, Thread::lazy_deopt_from_throw_stub_offset()));
   GenerateDeoptimizationSequence(assembler, kLazyDeoptFromThrow);
+  __ ret();
 }
 
 
 void StubCode::GenerateDeoptimizeStub(Assembler* assembler) {
   GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+  __ ret();
 }
 
 
@@ -1891,6 +1894,25 @@
 }
 
 
+// Deoptimize a frame on the call stack before rewinding.
+// The arguments are stored in the Thread object.
+// No result.
+void StubCode::GenerateDeoptForRewindStub(Assembler* assembler) {
+  // Push zap value instead of CODE_REG.
+  __ pushq(Immediate(kZapCodeReg));
+
+  // Push the deopt pc.
+  __ pushq(Address(THR, Thread::resume_pc_offset()));
+  GenerateDeoptimizationSequence(assembler, kEagerDeopt);
+
+  // After we have deoptimized, jump to the correct frame.
+  __ EnterStubFrame();
+  __ CallRuntime(kRewindPostDeoptRuntimeEntry, 0);
+  __ LeaveStubFrame();
+  __ int3();
+}
+
+
 // Calls to the runtime to optimize the given function.
 // RDI: function to be reoptimized.
 // R10: argument descriptor (preserved).
diff --git a/samples/samples.status b/samples/samples.status
index 2b249fd..caf91ca 100644
--- a/samples/samples.status
+++ b/samples/samples.status
@@ -23,5 +23,5 @@
 [ $compiler == precompiler ]
 sample_extension/test/*: Skip # These tests attempt to spawn another script using the precompiled runtime.
 
-[ $runtime == dart_app ]
+[ $compiler == app_jit ]
 sample_extension/test/*: Skip # Shared use of a temp directory
diff --git a/sdk/lib/_internal/js_runtime/lib/convert_patch.dart b/sdk/lib/_internal/js_runtime/lib/convert_patch.dart
index 1b987ed..9cac10e 100644
--- a/sdk/lib/_internal/js_runtime/lib/convert_patch.dart
+++ b/sdk/lib/_internal/js_runtime/lib/convert_patch.dart
@@ -382,7 +382,7 @@
   final Sink<Object> _sink;
 
   _JsonDecoderSink(this._reviver, this._sink)
-      : super(new StringBuffer());
+      : super(new StringBuffer(''));
 
   void close() {
     super.close();
diff --git a/sdk/lib/_internal/js_runtime/lib/core_patch.dart b/sdk/lib/_internal/js_runtime/lib/core_patch.dart
index 5c5ec25..c6aa41e 100644
--- a/sdk/lib/_internal/js_runtime/lib/core_patch.dart
+++ b/sdk/lib/_internal/js_runtime/lib/core_patch.dart
@@ -20,7 +20,8 @@
                               patch_startup,
                               Primitives,
                               stringJoinUnchecked,
-                              getTraceFromException;
+                              getTraceFromException,
+                              RuntimeError;
 
 import 'dart:_foreign_helper' show JS;
 
@@ -548,7 +549,7 @@
 class NoSuchMethodError {
   @patch
   String toString() {
-    StringBuffer sb = new StringBuffer();
+    StringBuffer sb = new StringBuffer('');
     String comma = '';
     if (_arguments != null) {
       for (var argument in _arguments) {
@@ -620,7 +621,7 @@
 
     // Encode the string into bytes then generate an ASCII only string
     // by percent encoding selected bytes.
-    StringBuffer result = new StringBuffer();
+    StringBuffer result = new StringBuffer('');
     var bytes = encoding.encode(text);
     for (int i = 0; i < bytes.length; i++) {
       int byte = bytes[i];
@@ -667,3 +668,30 @@
     }
   }
 }
+
+// Called from kernel generated code.
+_genericNoSuchMethod(receiver, memberName, positionalArguments, namedArguments,
+    existingArguments) {
+  return new NoSuchMethodError(
+      receiver,
+      memberName,
+      positionalArguments,
+      namedArguments);
+}
+
+// Called from kernel generated code.
+_unresolvedConstructorError(receiver, memberName, positionalArguments,
+    namedArguments, existingArguments) {
+  // TODO(sra): Generate an error that reads:
+  //
+  //     No constructor '$memberName' declared in class '$receiver'.
+
+  return new NoSuchMethodError(
+      receiver,
+      memberName,
+      positionalArguments,
+      namedArguments);
+}
+
+// Called from kernel generated code.
+_malformedTypeError(message) => new RuntimeError(message);
diff --git a/sdk/lib/_internal/js_runtime/lib/js_rti.dart b/sdk/lib/_internal/js_runtime/lib/js_rti.dart
index ba18319..0ce3e69 100644
--- a/sdk/lib/_internal/js_runtime/lib/js_rti.dart
+++ b/sdk/lib/_internal/js_runtime/lib/js_rti.dart
@@ -188,7 +188,7 @@
   assert(isJsArray(types));
   bool firstArgument = true;
   bool allDynamic = true;
-  StringBuffer buffer = new StringBuffer();
+  StringBuffer buffer = new StringBuffer('');
   for (int index = startIndex; index < getLength(types); index++) {
     if (firstArgument) {
       firstArgument = false;
diff --git a/sdk/lib/_internal/js_runtime/lib/string_helper.dart b/sdk/lib/_internal/js_runtime/lib/string_helper.dart
index 24e21f7..8ec6c47 100644
--- a/sdk/lib/_internal/js_runtime/lib/string_helper.dart
+++ b/sdk/lib/_internal/js_runtime/lib/string_helper.dart
@@ -144,7 +144,7 @@
       if (receiver == "") {
         return replacement;
       } else {
-        StringBuffer result = new StringBuffer();
+        StringBuffer result = new StringBuffer('');
         int length = receiver.length;
         result.write(replacement);
         for (int i = 0; i < length; i++) {
@@ -184,7 +184,7 @@
   if (pattern is! Pattern) {
     throw new ArgumentError.value(pattern, 'pattern', 'is not a Pattern');
   }
-  StringBuffer buffer = new StringBuffer();
+  StringBuffer buffer = new StringBuffer('');
   int startIndex = 0;
   for (Match match in pattern.allMatches(receiver)) {
     buffer.write(onNonMatch(receiver.substring(startIndex, match.start)));
@@ -197,7 +197,7 @@
 
 stringReplaceAllEmptyFuncUnchecked(receiver, onMatch, onNonMatch) {
   // Pattern is the empty string.
-  StringBuffer buffer = new StringBuffer();
+  StringBuffer buffer = new StringBuffer('');
   int length = receiver.length;
   int i = 0;
   buffer.write(onNonMatch(""));
@@ -229,7 +229,7 @@
     return stringReplaceAllEmptyFuncUnchecked(receiver, onMatch, onNonMatch);
   }
   int length = receiver.length;
-  StringBuffer buffer = new StringBuffer();
+  StringBuffer buffer = new StringBuffer('');
   int startIndex = 0;
   while (startIndex < length) {
     int position = stringIndexOfStringUnchecked(receiver, pattern, startIndex);
diff --git a/sdk/lib/async/zone.dart b/sdk/lib/async/zone.dart
index b81a7fe..ea3f47f 100644
--- a/sdk/lib/async/zone.dart
+++ b/sdk/lib/async/zone.dart
@@ -399,7 +399,7 @@
    * the current's zone behavior. All specification entries that are `null`
    * inherit the behavior from the parent zone (`this`).
    *
-   * The new zone inherits the stored values (accessed through [operator []])
+   * The new zone inherits the stored values (accessed through [[]])
    * of this zone and updates them with values from [zoneValues], which either
    * adds new values or overrides existing ones.
    *
diff --git a/sdk/lib/collection/hash_map.dart b/sdk/lib/collection/hash_map.dart
index d934e8c..6824328 100644
--- a/sdk/lib/collection/hash_map.dart
+++ b/sdk/lib/collection/hash_map.dart
@@ -17,7 +17,7 @@
 /**
  * A hash-table based implementation of [Map].
  *
- * The keys of a `HashMap` must have consistent [Object.operator==]
+ * The keys of a `HashMap` must have consistent [Object.==]
  * and [Object.hashCode] implementations. This means that the `==` operator
  * must define a stable equivalence relation on the keys (reflexive,
  * symmetric, transitive, and consistent over time), and that `hashCode`
@@ -41,14 +41,14 @@
    * same as long as the map isn't changed.
    *
    * If [equals] is provided, it is used to compare the keys in the table with
-   * new keys. If [equals] is omitted, the key's own [Object.operator==] is used
+   * new keys. If [equals] is omitted, the key's own [Object.==] is used
    * instead.
    *
    * Similar, if [hashCode] is provided, it is used to produce a hash value
    * for keys in order to place them in the hash table. If it is omitted, the
    * key's own [Object.hashCode] is used.
    *
-   * If using methods like [operator[]], [remove] and [containsKey] together
+   * If using methods like [[]], [remove] and [containsKey] together
    * with a custom equality and hashcode, an extra `isValidKey` function
    * can be supplied. This function is called before calling [equals] or
    * [hashCode] with an argument that may not be a [K] instance, and if the
diff --git a/sdk/lib/collection/hash_set.dart b/sdk/lib/collection/hash_set.dart
index 8e2a2a1..89558f8 100644
--- a/sdk/lib/collection/hash_set.dart
+++ b/sdk/lib/collection/hash_set.dart
@@ -62,7 +62,7 @@
    * to not be in the set when asking `contains`.
    *
    * If [equals] or [hashCode] are omitted, the set uses
-   * the elements' intrinsic [Object.operator==] and [Object.hashCode].
+   * the elements' intrinsic [Object.==] and [Object.hashCode].
    *
    * If you supply one of [equals] and [hashCode],
    * you should generally also to supply the other.
diff --git a/sdk/lib/collection/linked_hash_map.dart b/sdk/lib/collection/linked_hash_map.dart
index d4ce4ca..fe21eea 100644
--- a/sdk/lib/collection/linked_hash_map.dart
+++ b/sdk/lib/collection/linked_hash_map.dart
@@ -15,7 +15,7 @@
  * but removing the key and adding it again
  * will make it be last in the iteration order.
  *
- * The keys of a `LinkedHashMap` must have consistent [Object.operator==]
+ * The keys of a `LinkedHashMap` must have consistent [Object.==]
  * and [Object.hashCode] implementations. This means that the `==` operator
  * must define a stable equivalence relation on the keys (reflexive,
  * symmetric, transitive, and consistent over time), and that `hashCode`
@@ -28,14 +28,14 @@
    * Creates an insertion-ordered hash-table based [Map].
    *
    * If [equals] is provided, it is used to compare the keys in the table with
-   * new keys. If [equals] is omitted, the key's own [Object.operator==] is used
+   * new keys. If [equals] is omitted, the key's own [Object.==] is used
    * instead.
    *
    * Similar, if [hashCode] is provided, it is used to produce a hash value
    * for keys in order to place them in the hash table. If it is omitted, the
    * key's own [Object.hashCode] is used.
    *
-   * If using methods like [operator[]], [remove] and [containsKey] together
+   * If using methods like [[]], [remove] and [containsKey] together
    * with a custom equality and hashcode, an extra `isValidKey` function
    * can be supplied. This function is called before calling [equals] or
    * [hashCode] with an argument that may not be a [K] instance, and if the
diff --git a/sdk/lib/collection/linked_hash_set.dart b/sdk/lib/collection/linked_hash_set.dart
index 5addba5..d07c7e9 100644
--- a/sdk/lib/collection/linked_hash_set.dart
+++ b/sdk/lib/collection/linked_hash_set.dart
@@ -10,7 +10,7 @@
  * The `LinkedHashSet` also keep track of the order that elements were inserted
  * in, and iteration happens in first-to-last insertion order.
  *
- * The elements of a `LinkedHashSet` must have consistent [Object.operator==]
+ * The elements of a `LinkedHashSet` must have consistent [Object.==]
  * and [Object.hashCode] implementations. This means that the `==` operator
  * must define a stable equivalence relation on the elements (reflexive,
  * symmetric, transitive, and consistent over time), and that `hashCode`
@@ -43,7 +43,7 @@
    * to not be in the set when asking `contains`.
    *
    * If [equals] or [hashCode] are omitted, the set uses
-   * the elements' intrinsic [Object.operator==] and [Object.hashCode],
+   * the elements' intrinsic [Object.==] and [Object.hashCode],
    * and [isValidKey] is ignored since these operations are assumed
    * to work on all objects.
    *
diff --git a/sdk/lib/collection/maps.dart b/sdk/lib/collection/maps.dart
index d5b8621..c928287 100644
--- a/sdk/lib/collection/maps.dart
+++ b/sdk/lib/collection/maps.dart
@@ -214,8 +214,8 @@
 
 /**
  * Helper class which implements complex [Map] operations
- * in term of basic ones ([Map.keys], [Map.operator []],
- * [Map.operator []=] and [Map.remove].)  Not all methods are
+ * in term of basic ones ([Map.keys], [Map.[]],
+ * [Map.[]=] and [Map.remove].)  Not all methods are
  * necessary to implement each particular operation.
  */
 class Maps {
diff --git a/sdk/lib/collection/queue.dart b/sdk/lib/collection/queue.dart
index 2e6a24a..69b18d2 100644
--- a/sdk/lib/collection/queue.dart
+++ b/sdk/lib/collection/queue.dart
@@ -322,7 +322,12 @@
   bool remove(Object o) {
     _DoubleLinkedQueueEntry<E> entry = _sentinel._nextLink;
     while (!identical(entry, _sentinel)) {
-      if (entry._element == o) {
+      bool equals = (entry._element == o);
+      if (!identical(this, entry._queue)) {
+        // Entry must still be in the queue.
+        throw new ConcurrentModificationError(this);
+      }
+      if (equals) {
         entry._remove();
         _elementCount--;
         return true;
@@ -335,8 +340,13 @@
   void _filter(bool test(E element), bool removeMatching) {
     _DoubleLinkedQueueEntry<E> entry = _sentinel._nextLink;
     while (!identical(entry, _sentinel)) {
-      _DoubleLinkedQueueEntry<E> next = entry._nextLink;
-      if (identical(removeMatching, test(entry._element))) {
+      bool matches = test(entry._element);
+      if (!identical(this, entry._queue)) {
+        // Entry must still be in the queue.
+        throw new ConcurrentModificationError(this);
+      }
+      _DoubleLinkedQueueEntry<E> next = entry._nextLink;  // Cannot be null.
+      if (identical(removeMatching, matches)) {
         entry._remove();
         _elementCount--;
       }
@@ -364,7 +374,7 @@
 
   E get single {
     // Note that this throws correctly if the queue is empty
-    // because reading element on the sentinel throws.
+    // because reading the element of the sentinel throws.
     if (identical(_sentinel._nextLink, _sentinel._previousLink)) {
       _DoubleLinkedQueueEntry<E> entry = _sentinel._nextLink;
       return entry._element;
@@ -372,14 +382,34 @@
     throw IterableElementError.tooMany();
   }
 
-  DoubleLinkedQueueEntry<E> lastEntry() {
-    return _sentinel.previousEntry();
-  }
-
+  /**
+   * The entry object of the first element in the queue.
+   *
+   * Each element of the queue has an associated [DoubleLinkedQueueEntry].
+   * Returns the entry object corresponding to the first element of the queue.
+   *
+   * The entry objects can also be accessed using [lastEntry],
+   * and they can be iterated using [DoubleLinkedQueueEntry.nextEntry()] and
+   * [DoubleLinkedQueueEntry.previousEntry()].
+   */
   DoubleLinkedQueueEntry<E> firstEntry() {
     return _sentinel.nextEntry();
   }
 
+  /**
+   * The entry object of the last element in the queue.
+   *
+   * Each element of the queue has an associated [DoubleLinkedQueueEntry].
+   * Returns the entry object corresponding to the last element of the queue.
+   *
+   * The entry objects can also be accessed using [firstEntry],
+   * and they can be iterated using [DoubleLinkedQueueEntry.nextEntry()] and
+   * [DoubleLinkedQueueEntry.previousEntry()].
+   */
+  DoubleLinkedQueueEntry<E> lastEntry() {
+    return _sentinel.previousEntry();
+  }
+
   bool get isEmpty {
     return (identical(_sentinel._nextLink, _sentinel));
   }
@@ -390,13 +420,40 @@
     _elementCount = 0;
   }
 
-  void forEachEntry(void f(DoubleLinkedQueueEntry<E> element)) {
+  /**
+   * Calls [action] for each entry object of this double-linked queue.
+   *
+   * Each element of the queue has an associated [DoubleLinkedQueueEntry].
+   * This method iterates the entry objects from first to last and calls
+   * [action] with each object in turn.
+   *
+   * The entry objects can also be accessed using [firstEntry] and [lastEntry],
+   * and iterated using [DoubleLinkedQueueEntry.nextEntry()] and
+   * [DoubleLinkedQueueEntry.previousEntry()].
+   *
+   * The [action] function can use methods on [DoubleLinkedQueueEntry] to remove
+   * the entry or it can insert elements before or after then entry.
+   * If the current entry is removed, iteration continues with the entry that
+   * was following the current entry when [action] was called. Any elements
+   * inserted after the current element before it is removed will not be
+   * visited by the iteration.
+   */
+  void forEachEntry(void action(DoubleLinkedQueueEntry<E> element)) {
     _DoubleLinkedQueueEntry<E> entry = _sentinel._nextLink;
     while (!identical(entry, _sentinel)) {
-      _DoubleLinkedQueueEntry<E> nextEntry = entry._nextLink;
       _DoubleLinkedQueueElement<E> element = entry;
-      f(element);
-      entry = nextEntry;
+      _DoubleLinkedQueueEntry<E> next = element._nextLink;
+      // Remember both entry and entry._nextLink.
+      // If someone calls `element.remove()` we continue from `next`.
+      // Otherwise we use the value of entry._nextLink which may have been
+      // updated.
+      action(element);
+      if (identical(this, entry._queue)) {
+        next = entry._nextLink;
+      } else if (!identical(this, next._queue)) {
+        throw new ConcurrentModificationError(this);
+      }
+      entry = next;
     }
   }
 
@@ -424,7 +481,7 @@
       return false;
     }
     _DoubleLinkedQueueElement<E> elementEntry = _nextEntry;
-    if (elementEntry._queue == null) {
+    if (!identical(_sentinel._queue, elementEntry._queue)) {
       throw new ConcurrentModificationError(_sentinel._queue);
     }
     _current = elementEntry._element;
@@ -714,7 +771,7 @@
   /**
    * Removes the element at [offset] into [_table].
    *
-   * Removal is performed by linerarly moving elements either before or after
+   * Removal is performed by linearly moving elements either before or after
    * [offset] by one position.
    *
    * Returns the new offset of the following element. This may be the same
diff --git a/sdk/lib/collection/splay_tree.dart b/sdk/lib/collection/splay_tree.dart
index 9a41ef3..ef646f3 100644
--- a/sdk/lib/collection/splay_tree.dart
+++ b/sdk/lib/collection/splay_tree.dart
@@ -260,7 +260,7 @@
  * Non-comparable objects (including `null`) will not work as keys
  * in that case.
  *
- * To allow calling [operator[]], [remove] or [containsKey] with objects
+ * To allow calling [[]], [remove] or [containsKey] with objects
  * that are not supported by the `compare` function, an extra `isValidKey`
  * predicate function can be supplied. This function is tested before
  * using the `compare` function on an argument value that may not be a [K]
diff --git a/sdk/lib/core/iterable.dart b/sdk/lib/core/iterable.dart
index 9ea0c02..770465b 100644
--- a/sdk/lib/core/iterable.dart
+++ b/sdk/lib/core/iterable.dart
@@ -204,7 +204,7 @@
    * equal to [element].
    *
    * The equality used to determine whether [element] is equal to an element of
-   * the iterable defaults to the [Object.operator==] of the element.
+   * the iterable defaults to the [Object.==] of the element.
    *
    * Some types of iterable may have a different equality used for its elements.
    * For example, a [Set] may have a custom equality
diff --git a/sdk/lib/core/map.dart b/sdk/lib/core/map.dart
index ac4581f..1c29a90 100644
--- a/sdk/lib/core/map.dart
+++ b/sdk/lib/core/map.dart
@@ -237,6 +237,9 @@
    *
    * The order of iteration is defined by the individual `Map` implementation,
    * but must be consistent between changes to the map.
+   *
+   * Modifying the map while iterating the keys
+   * may break the iteration.
    */
   Iterable<K> get keys;
 
@@ -250,6 +253,9 @@
    * The returned iterable has an efficient `length` method based on the
    * [length] of the map. Its [Iterable.contains] method is based on
    * `==` comparison.
+   *
+   * Modifying the map while iterating the
+   * values may break the iteration.
    */
   Iterable<V> get values;
 
diff --git a/sdk/lib/core/num.dart b/sdk/lib/core/num.dart
index 21f23ee..83b4925 100644
--- a/sdk/lib/core/num.dart
+++ b/sdk/lib/core/num.dart
@@ -51,7 +51,7 @@
    * for an [int] and a [double] with the same numerical value, and therefore
    * the same value for the doubles zero and minus zero.
    *
-   * No guarantees are made about the hash code of NaN.
+   * No guarantees are made about the hash code of NaN values.
    */
   int get hashCode;
 
@@ -66,16 +66,40 @@
    * but integers are equal to doubles if they have the same numerical
    * value.
    *
-   * For ordering, the double NaN value is considered equal to itself, and
-   * greater than any numeric value (unlike its behavior in `operator==`).
+   * For doubles, the `compareTo` operation is different from the partial
+   * ordering given by [operator==], [operator<] and [operator>]. For example,
+   * IEEE doubles impose that `0.0 == -0.0` and all comparison operations on
+   * NaN return false.
    *
-   * The double value -0.0 is considered less than 0.0 (and the integer 0), but
-   * greater than any non-zero negative value.
+   * This function imposes a complete ordering for doubles. When using
+   * `compareTo` the following properties hold:
    *
-   * Positive infinity is greater than any finite value (any value apart from
-   * itself and NaN), and negative infinity is less than any other value.
+   * - All NaN values are considered equal, and greater than any numeric value.
+   * - -0.0 is less than 0.0 (and the integer 0), but greater than any non-zero
+   *    negative value.
+   * - Negative infinity is less than all other values and positive infinity is
+   *   greater than all non-NaN values.
+   * - All other values are compared using their numeric value.
    *
-   * All other values are compared using their numeric value.
+   * Examples:
+   * ```
+   * print(1.compareTo(2)); // => -1
+   * print(2.compareTo(1)); // => 1
+   * print(1.compareTo(1)); // => 0
+   *
+   * // The following comparisons yield different results than the
+   * // corresponding comparison operators.
+   * print((-0.0).compareTo(0.0));  // => -1
+   * print(double.NAN.compareTo(double.NAN));  // => 0
+   * print(double.INFINITY.compareTo(double.NAN)); // => -1
+   *
+   * // -0.0, and NaN comparison operators have rules imposed by the IEEE
+   * // standard.
+   * print(-0.0 == 0.0); // => true
+   * print(double.NAN == double.NAN);  // => false
+   * print(double.INFINITY < double.NAN);  // => false
+   * print(double.NAN < double.INFINITY);  // => false
+   * print(double.NAN == double.INFINITY);  // => false
    */
   int compareTo(num other);
 
@@ -162,7 +186,7 @@
   /**
    * True if the number is finite; otherwise, false.
    *
-   * The only non-finite numbers are NaN, positive infinitity and
+   * The only non-finite numbers are NaN, positive infinity, and
    * negative infinity.
    */
   bool get isFinite;
@@ -296,6 +320,9 @@
    * The comparison is done using [compareTo] and therefore takes `-0.0` into
    * account. This also implies that [double.NAN] is treated as the maximal
    * double value.
+   *
+   * The arguments [lowerLimit] and [upperLimit] must form a valid range where
+   * `lowerLimit.compareTo(upperLimit) <= 0`.
    */
   num clamp(num lowerLimit, num upperLimit);
 
diff --git a/sdk/lib/core/string.dart b/sdk/lib/core/string.dart
index 39641df..40d87bf 100644
--- a/sdk/lib/core/string.dart
+++ b/sdk/lib/core/string.dart
@@ -187,7 +187,7 @@
   /**
    * Returns a hash code derived from the code units of the string.
    *
-   * This is compatible with [operator==]. Strings with the same sequence
+   * This is compatible with [==]. Strings with the same sequence
    * of code units have the same hash code.
    */
   int get hashCode;
diff --git a/sdk/lib/io/process.dart b/sdk/lib/io/process.dart
index 6159113..c0781fe 100644
--- a/sdk/lib/io/process.dart
+++ b/sdk/lib/io/process.dart
@@ -229,7 +229,7 @@
    * get the original 32-bit value use `(0x100000000 + exitCode) &
    * 0xffffffff`.
    */
-  Future<int> exitCode;
+  Future<int> get exitCode;
 
   /**
    * Starts a process running the [executable] with the specified
diff --git a/sdk/lib/isolate/isolate.dart b/sdk/lib/isolate/isolate.dart
index 77b40c0..424742a 100644
--- a/sdk/lib/isolate/isolate.dart
+++ b/sdk/lib/isolate/isolate.dart
@@ -50,13 +50,16 @@
  * for example by pausing the isolate or by getting events when the isolate
  * has an uncaught error.
  *
- * The [controlPort] gives access to controlling the isolate, and the
- * [pauseCapability] and [terminateCapability] guard access to some control
- * operations.
+ * The [controlPort] identifies and gives access to controlling the isolate,
+ * and the [pauseCapability] and [terminateCapability] guard access
+ * to some control operations.
+ * For example, calling [pause] on an `Isolate` object created without a
+ * [pauseCapability], has no effect.
+ *
  * The `Isolate` object provided by a spawn operation will have the
  * control port and capabilities needed to control the isolate.
- * New isolates objects can be created without some of these capabilities
- * if necessary.
+ * New isolate objects can be created without some of these capabilities
+ * if necessary, using the [Isolate.Isolate] constructor.
  *
  * An `Isolate` object cannot be sent over a `SendPort`, but the control port
  * and capabilities can be sent, and can be used to create a new functioning
@@ -71,22 +74,26 @@
   /**
    * Control port used to send control messages to the isolate.
    *
-   * This class provides helper functions that sends control messages
-   * to the control port.
-   *
    * The control port identifies the isolate.
+   *
+   * An `Isolate` object allows sending control messages
+   * through the control port.
+   *
+   * Some control messages require a specific capability to be passed along
+   * with the message (see [pauseCapability] and [terminateCapaibility]),
+   * otherwise the message is ignored by the isolate.
    */
   final SendPort controlPort;
 
   /**
    * Capability granting the ability to pause the isolate.
    *
-   * This capability is used by [pause].
-   * If the capability is not the correct pause capability of the isolate,
-   * including if the capability is `null`, then calls to `pause` will have no
-   * effect.
+   * This capability is required by [pause].
+   * If the capability is `null`, or if it is not the correct pause capability
+   * of the isolate identified by [controlPort],
+   * then calls to [pause] will have no effect.
    *
-   * If the isolate is started in a paused state, use this capability as
+   * If the isolate is spawned in a paused state, use this capability as
    * argument to [resume] to resume the isolate.
    */
   final Capability pauseCapability;
@@ -94,10 +101,10 @@
   /**
    * Capability granting the ability to terminate the isolate.
    *
-   * This capability is used by [kill] and [setErrorsFatal].
-   * If the capability is not the correct termination capability of the isolate,
-   * including if the capability is `null`, then calls to those methods will
-   * have no effect.
+   * This capability is required by [kill] and [setErrorsFatal].
+   * If the capability is `null`, or if it is not the correct termination
+   * capability of the isolate identified by [controlPort],
+   * then calls to those methods will have no effect.
    */
   final Capability terminateCapability;
 
@@ -113,10 +120,18 @@
    * anywhere else, so the capabilities should come from the same isolate as
    * the control port.
    *
-   * If all the available capabilities are included,
-   * there is no reason to create a new object,
-   * since the behavior is defined entirely
-   * by the control port and capabilities.
+   * Can also be used to create an [Isolate] object from a control port, and
+   * any available capabilities, that have been sent through a [SendPort].
+   *
+   * Example:
+   * ```dart
+   * Isolate isolate = findSomeIsolate();
+   * Isolate restrictedIsolate = new Isolate(isolate.controlPort);
+   * untrustedCode(restrictedIsolate);
+   * ```
+   * This example creates a new `Isolate` object that cannot be used to
+   * pause or terminate the isolate. All the untrusted code can do is to
+   * inspect the isolate and see uncaught errors or when it terminates.
    */
   Isolate(this.controlPort, {this.pauseCapability,
                              this.terminateCapability});
@@ -305,17 +320,18 @@
    * When the isolate receives the pause command, it stops
    * processing events from the event loop queue.
    * It may still add new events to the queue in response to, e.g., timers
-   * or receive-port messages. When the isolate is resumed, it handles
-   * the already enqueued events.
+   * or receive-port messages. When the isolate is resumed,
+   * it starts handling the already enqueued events.
    *
    * The pause request is sent through the isolate's command port,
    * which bypasses the receiving isolate's event loop.
    * The pause takes effect when it is received, pausing the event loop
    * as it is at that time.
    *
-   * If [resumeCapability] is provided, it is used to identity the pause,
+   * The [resumeCapability] is used to identity the pause,
    * and must be used again to end the pause using [resume].
-   * Otherwise a new resume capability is created and returned.
+   * If [resumeCapability] is omitted, a new capability object is created
+   * and used instead.
    *
    * If an isolate is paused more than once using the same capability,
    * only one resume with that capability is needed to end the pause.
@@ -324,6 +340,12 @@
    * each pause must be individually ended before the isolate resumes.
    *
    * Returns the capability that must be used to end the pause.
+   * This is either [resumeCapability], or a new capability when
+   * [resumeCapability] is omitted.
+   *
+   * If [pauseCapability] is `null`, or it's not the pause capability
+   * of the isolate identified by [controlPort],
+   * the pause request is ignored by the receiving isolate.
    */
   Capability pause([Capability resumeCapability]) {
     resumeCapability ??= new Capability();
@@ -338,13 +360,14 @@
    * Resumes a paused isolate.
    *
    * Sends a message to an isolate requesting that it ends a pause
-   * that was requested using the [resumeCapability].
+   * that was previously requested.
    *
    * When all active pause requests have been cancelled, the isolate
    * will continue processing events and handling normal messages.
    *
-   * The capability must be one returned by a call to [pause] on this
-   * isolate, otherwise the resume call does nothing.
+   * If the [resumeCapability] is not one that has previously been used
+   * to pause the isolate, or it has already been used to resume from
+   * that pause, the resume call has no effect.
    */
   external void resume(Capability resumeCapability);
 
@@ -393,7 +416,7 @@
    * event loop and shut down the isolate.
    *
    * This call requires the [terminateCapability] for the isolate.
-   * If the capability is not correct, no change is made.
+   * If the capability absent or wrong, no change is made.
    *
    * Since isolates run concurrently, it's possible for it to exit due to an
    * error before errors are set non-fatal.
@@ -423,6 +446,10 @@
    *     control returns to the event loop of the receiving isolate,
    *     after the current event, and any already scheduled control events,
    *     are completed.
+   *
+   * If [terminateCapability] is `null`, or it's not the terminate capability
+   * of the isolate identified by [controlPort],
+   * the kill request is ignored by the receiving isolate.
    */
   external void kill({int priority: BEFORE_NEXT_EVENT});
 
diff --git a/tests/benchmark_smoke/benchmark_smoke.status b/tests/benchmark_smoke/benchmark_smoke.status
index 056911f..de17765 100644
--- a/tests/benchmark_smoke/benchmark_smoke.status
+++ b/tests/benchmark_smoke/benchmark_smoke.status
@@ -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.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 *: Skip
 
 [ $compiler == dart2js && $runtime == none ]
diff --git a/tests/co19/co19-co19.status b/tests/co19/co19-co19.status
index 957c549..3233640 100644
--- a/tests/co19/co19-co19.status
+++ b/tests/co19/co19-co19.status
@@ -68,7 +68,7 @@
 [ $runtime == dartium || $compiler == dart2js ]
 LibTest/async/Future/Future.delayed_A01_t02: Pass, Fail # Issue 15524
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && ($runtime == vm || $runtime == drt || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && ($runtime == vm || $runtime == drt || $runtime == dart_precompiled) ]
 # Optional trailing commas for argument and parameter lists added to language.
 # https://github.com/dart-lang/co19/issues/68
 Language/Functions/Formal_Parameters/syntax_t05: Fail, OK
diff --git a/tests/co19/co19-dart2js.status b/tests/co19/co19-dart2js.status
index ba7e90e..f2b0d5f 100644
--- a/tests/co19/co19-dart2js.status
+++ b/tests/co19/co19-dart2js.status
@@ -1002,6 +1002,8 @@
 LayoutTests/fast/canvas/webgl/buffer-data-array-buffer_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/context-attributes-alpha-depth-stencil-antialias-t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/context-lost-restored_t01: Pass, Timeout # Please triage this failure
+LayoutTests/fast/canvas/webgl/gl-get-calls_t01: RuntimeError # Please triage this failure
+LayoutTests/fast/canvas/webgl/object-deletion-behaviour_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/oes-vertex-array-object_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgb565_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba4444_t01: RuntimeError # Please triage this failure
@@ -1097,7 +1099,6 @@
 LayoutTests/fast/css/getComputedStyle/computed-style-border-image_t01: RuntimeError # co19 issue 14
 LayoutTests/fast/css/getComputedStyle/computed-style-cross-fade_t01: RuntimeError # co19 issue 14
 LayoutTests/fast/css/getComputedStyle/font-family-fallback-reset_t01: RuntimeError # Please triage this failure
-LayoutTests/fast/css/getComputedStyle/getComputedStyle-zIndex-auto_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/css/getPropertyValue-border_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/css/html-attr-case-sensitivity_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/css/id-or-class-before-stylesheet_t01: RuntimeError # Please triage this failure
@@ -1168,6 +1169,7 @@
 LayoutTests/fast/dom/HTMLAnchorElement/set-href-attribute-protocol_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/HTMLAnchorElement/set-href-attribute-search_t01: Pass, RuntimeError # Please triage this failure
 LayoutTests/fast/dom/HTMLDialogElement/dialog-autofocus_t01: RuntimeError # Please triage this failure
+LayoutTests/fast/dom/HTMLDialogElement/dialog-close-event_t01: RuntimeError
 LayoutTests/fast/dom/HTMLDialogElement/dialog-scrolled-viewport_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/HTMLDialogElement/inert-node-is-unfocusable_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/HTMLDialogElement/inert-node-is-unselectable_t01: RuntimeError # Please triage this failure
@@ -1205,6 +1207,7 @@
 LayoutTests/fast/dom/HTMLTemplateElement/innerHTML_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/HTMLTemplateElement/ownerDocumentXHTML_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/MutationObserver/observe-childList_t01: RuntimeError # Issue 18253
+LayoutTests/fast/dom/MutationObserver/removed-out-of-order_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/MutationObserver/weak-callback-gc-crash_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/Node/fragment-mutation_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/Node/initial-values_t01: RuntimeError # Please triage this failure
@@ -1262,6 +1265,7 @@
 LayoutTests/fast/dom/partial-layout-overlay-scrollbars_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/set-innerHTML_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/shadow/content-pseudo-element-css-text_t01: RuntimeError # https://github.com/dart-lang/co19/issues/49
+LayoutTests/fast/dom/shadow/distribution-update-recalcs-style_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/shadow/event-path_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/dom/shadow/host-context-pseudo-class-css-text_t01: RuntimeError # https://github.com/dart-lang/co19/issues/49
 LayoutTests/fast/dom/shadow/host-pseudo-class-css-text_t01: RuntimeError # https://github.com/dart-lang/co19/issues/49
@@ -1372,6 +1376,7 @@
 LayoutTests/fast/forms/setCustomValidity-existence_t01: RuntimeError # Issue 25155
 LayoutTests/fast/forms/setrangetext_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/forms/submit-form-attributes_t01: RuntimeError # co19 issue 14
+LayoutTests/fast/forms/textarea-maxlength_t01: RuntimeError # Please triage this failure. Started failing in chrome 55
 LayoutTests/fast/forms/textarea-paste-newline_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/forms/textfield-focus-out_t01: Skip # Times out. Please triage this failure
 LayoutTests/fast/forms/validationMessage_t01: RuntimeError # Please triage this failure
@@ -1556,6 +1561,7 @@
 LibTest/html/Document/clone_A01_t01: RuntimeError # Please triage this failure
 LibTest/html/Document/clone_A01_t02: RuntimeError # Please triage this failure
 LibTest/html/Document/securityPolicy_A01_t01: RuntimeError # Please triage this failure
+LibTest/html/Element/Element.tag_A01_t01: RuntimeError # Test seems invalid in Chrome 55.
 LibTest/html/Element/blur_A01_t01: Skip # Times out. Please triage this failure
 LibTest/html/Element/borderEdge_A01_t01: RuntimeError # Issue 16574
 LibTest/html/Element/contentEdge_A01_t01: RuntimeError # Issue 16574
@@ -1927,7 +1933,6 @@
 LayoutTests/fast/canvas/webgl/gl-bind-attrib-location-test_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/gl-enable-enum-test_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/gl-enum-tests_t01: RuntimeError # Please triage this failure
-LayoutTests/fast/canvas/webgl/gl-get-calls_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/gl-getshadersource_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/gl-getstring_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/gl-object-get-calls_t01: RuntimeError # Please triage this failure
@@ -1949,7 +1954,6 @@
 LayoutTests/fast/canvas/webgl/is-object_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/null-object-behaviour_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/null-uniform-location_t01: RuntimeError # Please triage this failure
-LayoutTests/fast/canvas/webgl/object-deletion-behaviour_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/oes-element-index-uint_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/point-size_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/premultiplyalpha-test_t01: RuntimeError # Please triage this failure
@@ -2848,7 +2852,6 @@
 LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba4444_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba5551_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image_t01: RuntimeError # Please triage this failure
-LayoutTests/fast/canvas/webgl/tex-input-validation_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/texture-transparent-pixels-initialized_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/uniform-location_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/canvas/webgl/uninitialized-test_t01: RuntimeError # Please triage this failure
@@ -4186,6 +4189,7 @@
 
 [ $compiler == dart2js && $runtime == ff && $system != windows ]
 LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-video_t01: RuntimeError # Please triage this failure
+LayoutTests/fast/canvas/webgl/tex-input-validation_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/xpath/4XPath/Core/test_parser_t01: RuntimeError # Dartium JSInterop failure
 LayoutTests/fast/xpath/py-dom-xpath/abbreviations_t01: RuntimeError # Dartium JSInterop failure
 
@@ -8102,7 +8106,7 @@
 LayoutTests/fast/xsl/xslt-string-parameters_t01: RuntimeError # Please triage this failure
 LayoutTests/fast/xsl/xslt-transform-to-fragment-crash_t01: RuntimeError # Please triage this failure
 LibTest/async/Future/doWhile_A05_t01: Pass, RuntimeError # Sometimes passes on windows 8. Please triage this failure
-LibTest/async/Future/forEach_A04_t02: RuntimeError # Please triage this failure
+LibTest/async/Future/forEach_A04_t02: Pass, RuntimeError # Sometimes passes on windows 7 and windows 8. Please triage this failure
 LibTest/async/Stream/Stream.periodic_A01_t01: Pass, RuntimeError # Please triage this failure
 LibTest/async/Stream/timeout_A01_t01: Pass, RuntimeError # Sometimes passes on windows 8. Please triage this failure
 LibTest/async/Stream/timeout_A03_t01: Pass, RuntimeError # Sometimes passes on windows 8. Please triage this failure
diff --git a/tests/co19/co19-dartium.status b/tests/co19/co19-dartium.status
index 3f61aa96..cfcf34d 100644
--- a/tests/co19/co19-dartium.status
+++ b/tests/co19/co19-dartium.status
@@ -1220,6 +1220,8 @@
 WebPlatformTest/shadow-dom/events/retargeting-focus-events/test-002_t01: Skip # Timesout sporadically
 WebPlatformTest/shadow-dom/events/retargeting-focus-events/test-003_t01: Skip # Timesout sporadically
 LayoutTests/fast/css/MarqueeLayoutTest_t01: Pass, RuntimeError # Please triage this failure
+LayoutTests/fast/dom/shadow/shadowhost-keyframes_t01: RuntimeError, Pass # Please triage this failure.
+LayoutTests/fast/dom/shadow/shadowroot-keyframes_t01: RuntimeError, Pass # Please triage this failure.
 
 [ $compiler == none && $runtime == dartium && $system != windows ]
 LayoutTests/fast/css/font-face-unicode-range-monospace_t01: RuntimeError # co19-roll r761: Please triage this failure.
diff --git a/tests/co19/co19-kernel.status b/tests/co19/co19-kernel.status
index 6b4334a..3ada69f 100644
--- a/tests/co19/co19-kernel.status
+++ b/tests/co19/co19-kernel.status
@@ -3,7 +3,7 @@
 # BSD-style license that can be found in the LICENSE file.
 
 # Disable tests globally for kernel.
-[ $compiler == rasta || $compiler == rastap || $compiler == dartk || $compiler == dartkp ]
+[ $compiler == dartk || $compiler == dartkp ]
 Language/Libraries_and_Scripts/Imports/static_type_t01: Skip # No support for deferred libraries.
 Language/Metadata/*: Skip # No support for metadata ATM.
 LibTest/async/DeferredLibrary/DeferredLibrary_A01_t01: Skip # No support for deferred libraries.
@@ -14,38 +14,329 @@
 Language/Libraries_and_Scripts/Exports/reexport_t01: Pass
 Language/Functions/Formal_Parameters/Optional_Formals/syntax_t14: Pass
 
+###############################################################################
+# Dartk Entries
+###############################################################################
+
+[ $compiler == dartk || $compiler == dartkp ]
+Language/Classes/Constructors/Generative_Constructors/formal_parameter_t01: DartkCrash
+Language/Classes/Constructors/Generative_Constructors/formal_parameter_t03: DartkCrash
+Language/Classes/Constructors/Generative_Constructors/formal_parameter_t04: DartkCrash
+Language/Classes/Constructors/Generative_Constructors/formal_parameter_t05: DartkCrash
+Language/Classes/Constructors/Generative_Constructors/formal_parameter_t06: DartkCrash
+Language/Classes/Constructors/Generative_Constructors/initializing_this_t02: DartkCrash
+Language/Classes/Getters/static_getter_t02: DartkCompileTimeError
+Language/Classes/Setters/name_t08: DartkCompileTimeError
+Language/Classes/Setters/name_t09: DartkCompileTimeError
+Language/Classes/Setters/name_t10: DartkCompileTimeError
+Language/Classes/Setters/name_t11: DartkCompileTimeError
+Language/Classes/Setters/name_t12: DartkCompileTimeError
+Language/Classes/Setters/name_t13: DartkCompileTimeError
+Language/Classes/Setters/name_t14: DartkCompileTimeError
+Language/Classes/Setters/name_t15: DartkCompileTimeError
+Language/Enums/syntax_t08: DartkMissingCompileTimeError
+Language/Enums/syntax_t09: DartkMissingCompileTimeError
+Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t03: DartkMissingCompileTimeError
+Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t04: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t17: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t18: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t21: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t22: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t23: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t24: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t25: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t26: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t27: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t28: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t29: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t30: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t31: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t32: DartkMissingCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/named_parameters_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/positional_parameters_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/deferred_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malbounded_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malbounded_type_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malformed_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malformed_type_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/no_such_method_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/no_such_method_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t08: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t09: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t08: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t08: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t09: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/static_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/static_type_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/static_type_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/static_type_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/static_type_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/static_type_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/General_Closurization/static_type_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Getter_Access_and_Method_Extraction/expression_evaluation_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Closurization/identical_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Closurization/identical_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Closurization/named_parameters_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Closurization/positional_parameters_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/closurization_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/closurization_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/deferred_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malbounded_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malbounded_type_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malformed_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malformed_type_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/no_such_method_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/no_such_method_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t08: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_named_params_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_named_params_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_positional_params_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_positional_params_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_list_access_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_list_assignment_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t08: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t09: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t10: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t11: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t12: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t13: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t14: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t15: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t16: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t17: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_unary_bitwise_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t01: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t02: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t03: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t04: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t05: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t06: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t07: DartkCompileTimeError
+Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t08: DartkCompileTimeError
+Language/Interfaces/Superinterfaces/Inheritance_and_Overriding/same_name_method_and_getter_t01: DartkCompileTimeError
+Language/Interfaces/Superinterfaces/Inheritance_and_Overriding/same_name_method_and_getter_t02: DartkCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t01: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t04: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t05: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t06: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/Imports/invalid_uri_deferred_t02: DartkCompileTimeError
+Language/Libraries_and_Scripts/Scripts/top_level_main_t01: DartkCrash
+Language/Libraries_and_Scripts/Scripts/top_level_main_t02: DartkCrash
+Language/Libraries_and_Scripts/definition_syntax_t01: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t03: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t04: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t06: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t07: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t08: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t09: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t10: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t15: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t17: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t18: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t19: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t20: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t21: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t22: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t23: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t24: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t25: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t26: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t27: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t29: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t02: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t03: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t04: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t05: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t06: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t07: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t08: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t09: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t10: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t11: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t12: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t13: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t14: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t15: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t16: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t17: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t18: DartkMissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t19: DartkMissingCompileTimeError
+Language/Statements/Break/label_t03: DartkMissingCompileTimeError
+Language/Statements/Break/label_t04: DartkMissingCompileTimeError
+Language/Statements/Continue/label_t07: DartkMissingCompileTimeError
+Language/Variables/final_or_static_initialization_t01: DartkMissingCompileTimeError
+Language/Variables/final_or_static_initialization_t02: DartkMissingCompileTimeError
+Language/Variables/final_or_static_initialization_t03: DartkMissingCompileTimeError
+Language/Variables/final_t04: DartkMissingCompileTimeError
+Language/Variables/final_t05: DartkMissingCompileTimeError
+Language/Variables/final_t06: DartkMissingCompileTimeError
+Language/Variables/final_t07: DartkMissingCompileTimeError
+
 # dartk: JIT failures
 [ $compiler == dartk && $runtime == vm ]
-Language/Classes/Constructors/Generative_Constructors/execution_of_a_superinitializer_t01: RuntimeError
-Language/Classes/Constructors/Generative_Constructors/execution_of_an_initializer_t02: RuntimeError
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t01: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t03: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t04: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t05: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t06: Crash
-Language/Classes/Constructors/Generative_Constructors/initializing_formals_execution_t02: RuntimeError
-Language/Classes/Constructors/Generative_Constructors/initializing_this_t02: Crash
-Language/Classes/Getters/static_getter_t02: CompileTimeError
-Language/Classes/Setters/name_t08: CompileTimeError
-Language/Classes/Setters/name_t09: CompileTimeError
-Language/Classes/Setters/name_t10: CompileTimeError
-Language/Classes/Setters/name_t11: CompileTimeError
-Language/Classes/Setters/name_t12: CompileTimeError
-Language/Classes/Setters/name_t13: CompileTimeError
-Language/Classes/Setters/name_t14: CompileTimeError
-Language/Classes/Setters/name_t15: CompileTimeError
-Language/Classes/definition_t23: CompileTimeError
-Language/Enums/declaration_equivalent_t01: RuntimeError
+Language/Expressions/Constants/exception_t01: DartkMissingCompileTimeError
+Language/Expressions/Constants/exception_t02: DartkMissingCompileTimeError
+Language/Expressions/Identifier_Reference/evaluation_type_parameter_t02: DartkMissingCompileTimeError
+Language/Mixins/Mixin_Application/error_t01: DartkMissingCompileTimeError
+Language/Mixins/Mixin_Application/error_t02: DartkMissingCompileTimeError
+Language/Mixins/Mixin_Application/syntax_t16: DartkCrash
+
+# dartk: precompilation failures
+[ $compiler == dartkp && $runtime == dart_precompiled ]
 Language/Enums/syntax_t08: MissingCompileTimeError
 Language/Enums/syntax_t09: MissingCompileTimeError
-Language/Expressions/Constants/exception_t01: MissingCompileTimeError
-Language/Expressions/Constants/exception_t02: MissingCompileTimeError
+Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t03: MissingCompileTimeError
+Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t04: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t17: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t18: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t21: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t22: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t23: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t24: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t25: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t26: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t27: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t28: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t29: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t30: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t31: MissingCompileTimeError
+Language/Expressions/Identifier_Reference/built_in_not_dynamic_t32: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t01: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t03: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t04: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t06: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t07: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t08: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t09: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t10: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t15: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t17: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t18: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t19: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t20: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t21: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t22: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t23: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t24: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t25: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t26: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t27: MissingCompileTimeError
+Language/Libraries_and_Scripts/definition_syntax_t29: MissingCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t01: MissingCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t04: MissingCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t05: MissingCompileTimeError
+Language/Libraries_and_Scripts/Exports/syntax_t06: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t02: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t03: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t04: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t05: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t06: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t07: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t08: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t09: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t10: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t11: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t12: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t13: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t14: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t15: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t16: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t17: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t18: MissingCompileTimeError
+Language/Libraries_and_Scripts/top_level_syntax_t19: MissingCompileTimeError
+Language/Statements/Break/label_t03: MissingCompileTimeError
+Language/Statements/Break/label_t04: MissingCompileTimeError
+Language/Statements/Continue/label_t07: MissingCompileTimeError
+Language/Variables/final_or_static_initialization_t01: MissingCompileTimeError
+Language/Variables/final_or_static_initialization_t02: MissingCompileTimeError
+Language/Variables/final_or_static_initialization_t03: MissingCompileTimeError
+Language/Variables/final_t04: MissingCompileTimeError
+Language/Variables/final_t05: MissingCompileTimeError
+Language/Variables/final_t06: MissingCompileTimeError
+Language/Variables/final_t07: MissingCompileTimeError
+
+###############################################################################
+# VM Entries
+###############################################################################
+
+# dartk: Shared JIT & Precompiled failures
+[ ($compiler == dartk && $runtime == vm) || ($compiler == dartkp && $runtime == dart_precompiled) ]
+Language/Classes/Constructors/Generative_Constructors/execution_of_a_superinitializer_t01: RuntimeError
+Language/Classes/Constructors/Generative_Constructors/execution_of_an_initializer_t02: RuntimeError
+Language/Classes/Constructors/Generative_Constructors/initializing_formals_execution_t02: RuntimeError
+Language/Classes/definition_t23: CompileTimeError
+Language/Enums/declaration_equivalent_t01: RuntimeError
 Language/Expressions/Constants/string_length_t01: Crash
 Language/Expressions/Function_Invocation/Function_Expression_Invocation/not_a_function_expression_t01: RuntimeError
 Language/Expressions/Function_Invocation/Unqualified_Invocation/function_expr_invocation_t03: RuntimeError
 Language/Expressions/Function_Invocation/Unqualified_Invocation/function_expr_invocation_t04: RuntimeError
-Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t03: MissingCompileTimeError
-Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t04: MissingCompileTimeError
 Language/Expressions/Function_Invocation/Unqualified_Invocation/static_method_invocation_t02: RuntimeError
 Language/Expressions/Function_Invocation/async_cleanup_t07: Fail
 Language/Expressions/Function_Invocation/async_cleanup_t08: Fail
@@ -56,24 +347,8 @@
 Language/Expressions/Identifier_Reference/built_in_identifier_t36: Pass
 Language/Expressions/Identifier_Reference/built_in_identifier_t37: Pass
 Language/Expressions/Identifier_Reference/built_in_not_dynamic_t14: Pass
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t17: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t18: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t21: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t22: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t23: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t24: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t25: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t26: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t27: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t28: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t29: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t30: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t31: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t32: MissingCompileTimeError
 Language/Expressions/Identifier_Reference/evaluation_property_extraction_t03: RuntimeError
 Language/Expressions/Identifier_Reference/evaluation_type_parameter_t01: RuntimeError
-Language/Expressions/Identifier_Reference/evaluation_type_parameter_t02: MissingCompileTimeError
-Language/Expressions/Instance_Creation/Const/canonicalized_t05: RuntimeError
 Language/Expressions/Instance_Creation/New/evaluation_t12: RuntimeError
 Language/Expressions/Instance_Creation/New/evaluation_t19: RuntimeError
 Language/Expressions/Instance_Creation/New/evaluation_t20: RuntimeError
@@ -81,207 +356,21 @@
 Language/Expressions/Method_Invocation/Ordinary_Invocation/accessible_instance_member_t05: RuntimeError
 Language/Expressions/Method_Invocation/Ordinary_Invocation/evaluation_t07: RuntimeError
 Language/Expressions/Method_Invocation/Ordinary_Invocation/method_lookup_failed_t18: RuntimeError
-Language/Expressions/Object_Identity/string_t01: RuntimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/named_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/positional_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/deferred_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malbounded_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malbounded_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malformed_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malformed_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/no_such_method_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/no_such_method_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t03: CompileTimeError
 Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t01: Pass
 Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t02: Pass
 Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t03: Pass
 Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t04: Pass
 Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t05: Pass
 Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t06: Pass
-Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t08: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t09: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t08: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t08: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t09: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Getter_Access_and_Method_Extraction/expression_evaluation_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/identical_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/identical_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/named_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/positional_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/deferred_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malbounded_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malbounded_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malformed_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malformed_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/no_such_method_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/no_such_method_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t05: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t06: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t08: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_named_params_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_named_params_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_positional_params_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_positional_params_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_list_access_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_list_assignment_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t05: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t06: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t08: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t09: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t10: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t11: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t12: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t13: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t14: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t15: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t16: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t17: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_unary_bitwise_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t05: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t06: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t08: CompileTimeError
-Language/Expressions/Strings/adjacent_strings_t02: RuntimeError
 Language/Expressions/Type_Test/evaluation_t10: RuntimeError
 Language/Functions/External_Functions/not_connected_to_a_body_t01: RuntimeError
 Language/Functions/Formal_Parameters/syntax_t05: RuntimeError
-Language/Interfaces/Superinterfaces/Inheritance_and_Overriding/same_name_method_and_getter_t01: CompileTimeError
-Language/Interfaces/Superinterfaces/Inheritance_and_Overriding/same_name_method_and_getter_t02: CompileTimeError
 Language/Libraries_and_Scripts/Exports/invalid_uri_t02: Pass
-Language/Libraries_and_Scripts/Exports/syntax_t01: MissingCompileTimeError
-Language/Libraries_and_Scripts/Exports/syntax_t04: MissingCompileTimeError
-Language/Libraries_and_Scripts/Exports/syntax_t05: MissingCompileTimeError
-Language/Libraries_and_Scripts/Exports/syntax_t06: MissingCompileTimeError
 Language/Libraries_and_Scripts/Imports/deferred_import_t01: RuntimeError
 Language/Libraries_and_Scripts/Imports/deferred_import_t02: RuntimeError
 Language/Libraries_and_Scripts/Imports/invalid_uri_deferred_t01/01: MissingRuntimeError
-Language/Libraries_and_Scripts/Imports/invalid_uri_deferred_t02: CompileTimeError
 Language/Libraries_and_Scripts/Imports/invalid_uri_t02: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01: RuntimeError
-Language/Libraries_and_Scripts/Parts/compilation_t02: Pass Crash
 Language/Libraries_and_Scripts/Parts/syntax_t06: Pass
-Language/Libraries_and_Scripts/Scripts/top_level_main_t01: Crash
-Language/Libraries_and_Scripts/Scripts/top_level_main_t02: Crash
-Language/Libraries_and_Scripts/definition_syntax_t01: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t03: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t04: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t06: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t07: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t08: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t09: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t10: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t15: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t17: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t18: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t19: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t20: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t21: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t22: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t23: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t24: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t25: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t26: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t27: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t29: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t02: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t03: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t04: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t05: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t06: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t07: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t08: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t09: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t10: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t11: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t12: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t13: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t14: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t15: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t16: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t17: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t18: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t19: MissingCompileTimeError
-Language/Mixins/Mixin_Application/error_t01: MissingCompileTimeError
-Language/Mixins/Mixin_Application/error_t02: MissingCompileTimeError
-Language/Mixins/Mixin_Application/syntax_t16: Crash
-Language/Statements/Break/label_t03: MissingCompileTimeError
-Language/Statements/Break/label_t04: MissingCompileTimeError
-Language/Statements/Continue/label_t07: MissingCompileTimeError
 Language/Statements/Labels/syntax_t03: Pass
 Language/Statements/Rethrow/execution_t04: RuntimeError
 Language/Statements/Switch/syntax_t02: Pass
@@ -292,321 +381,38 @@
 Language/Statements/Yield_and_Yield_Each/Yield_Each/execution_async_t01: RuntimeError
 Language/Types/Interface_Types/subtype_t44: RuntimeError
 Language/Types/Static_Types/deferred_type_t01: RuntimeError
-Language/Variables/final_or_static_initialization_t01: MissingCompileTimeError
-Language/Variables/final_or_static_initialization_t02: MissingCompileTimeError
-Language/Variables/final_or_static_initialization_t03: MissingCompileTimeError
 Language/Variables/final_t01/01: MissingRuntimeError
 Language/Variables/final_t02/01: MissingRuntimeError
-Language/Variables/final_t04: MissingCompileTimeError
-Language/Variables/final_t05: MissingCompileTimeError
-Language/Variables/final_t06: MissingCompileTimeError
-Language/Variables/final_t07: MissingCompileTimeError
+
+# dartk: JIT failures
+[ $compiler == dartk && $runtime == vm ]
+Language/Expressions/Instance_Creation/Const/canonicalized_t05: RuntimeError
+Language/Expressions/Object_Identity/string_t01: RuntimeError
+Language/Expressions/Strings/adjacent_strings_t02: RuntimeError
+Language/Libraries_and_Scripts/Imports/static_type_t01: RuntimeError
 
 # These tests should throw RuntimeError but they Pass instead.
-Language/Libraries_and_Scripts/Imports/static_type_t01/04: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/06: Pass
 Language/Libraries_and_Scripts/Imports/static_type_t01/01: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/05: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/03: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/07: Pass
 Language/Libraries_and_Scripts/Imports/static_type_t01/02: Pass
+Language/Libraries_and_Scripts/Imports/static_type_t01/03: Pass
 Language/Libraries_and_Scripts/Imports/static_type_t01/04: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/06: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/01: Pass
 Language/Libraries_and_Scripts/Imports/static_type_t01/05: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/03: Pass
+Language/Libraries_and_Scripts/Imports/static_type_t01/06: Pass
 Language/Libraries_and_Scripts/Imports/static_type_t01/07: Pass
-Language/Libraries_and_Scripts/Imports/static_type_t01/02: Pass
 
 # dartk: JIT failures (debug)
 [ $compiler == dartk && $runtime == vm && $mode == debug ]
 Language/Expressions/Shift/syntax_t15: Crash  # Invalid class id during isolate shutdown Heap::VerifyGC
 Language/Expressions/Spawning_an_Isolate/new_isolate_t01: Crash  # Class finalization issue
 Language/Libraries_and_Scripts/Scripts/top_level_main_t05: Crash  # !main_obj.IsNull()
-LibTest/typed_data/ByteBuffer/runtimeType_A01_t02: Pass, Crash  # Out of memory
-LibTest/collection/DoubleLinkedQueue/every_A01_t02: Pass, Crash  # Out of memory
 
 # dartk: precompilation failures
 [ $compiler == dartkp && $runtime == dart_precompiled ]
-Language/Classes/Constructors/Generative_Constructors/execution_of_a_superinitializer_t01: RuntimeError
-Language/Classes/Constructors/Generative_Constructors/execution_of_an_initializer_t02: RuntimeError
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t01: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t03: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t04: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t05: Crash
-Language/Classes/Constructors/Generative_Constructors/formal_parameter_t06: Crash
-Language/Classes/Constructors/Generative_Constructors/initializing_formals_execution_t02: RuntimeError
-Language/Classes/Constructors/Generative_Constructors/initializing_this_t02: Crash
-Language/Classes/Getters/static_getter_t02: CompileTimeError
-Language/Classes/Setters/name_t08: CompileTimeError
-Language/Classes/Setters/name_t09: CompileTimeError
-Language/Classes/Setters/name_t10: CompileTimeError
-Language/Classes/Setters/name_t11: CompileTimeError
-Language/Classes/Setters/name_t12: CompileTimeError
-Language/Classes/Setters/name_t13: CompileTimeError
-Language/Classes/Setters/name_t14: CompileTimeError
-Language/Classes/Setters/name_t15: CompileTimeError
-Language/Classes/definition_t23: CompileTimeError
-Language/Enums/declaration_equivalent_t01: RuntimeError
-Language/Enums/syntax_t08: MissingCompileTimeError
-Language/Enums/syntax_t09: MissingCompileTimeError
-Language/Expressions/Constants/exception_t01: Crash
-Language/Expressions/Constants/exception_t02: Crash
-Language/Expressions/Constants/string_length_t01: Crash
-Language/Expressions/Function_Invocation/Function_Expression_Invocation/not_a_function_expression_t01: RuntimeError
-Language/Expressions/Function_Invocation/Unqualified_Invocation/function_expr_invocation_t03: RuntimeError
-Language/Expressions/Function_Invocation/Unqualified_Invocation/function_expr_invocation_t04: RuntimeError
-Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t03: MissingCompileTimeError
-Language/Expressions/Function_Invocation/Unqualified_Invocation/instance_context_invocation_t04: MissingCompileTimeError
-Language/Expressions/Function_Invocation/Unqualified_Invocation/static_method_invocation_t02: RuntimeError
-Language/Expressions/Function_Invocation/async_cleanup_t07: RuntimeError
-Language/Expressions/Function_Invocation/async_cleanup_t08: RuntimeError
-Language/Expressions/Function_Invocation/async_generator_invokation_t05: RuntimeError
-Language/Expressions/Function_Invocation/async_generator_invokation_t06: RuntimeError
-Language/Expressions/Function_Invocation/async_generator_invokation_t09: RuntimeError
-Language/Expressions/Identifier_Reference/built_in_identifier_t35: Pass
-Language/Expressions/Identifier_Reference/built_in_identifier_t36: Pass
-Language/Expressions/Identifier_Reference/built_in_identifier_t37: Pass
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t14: Pass
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t17: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t18: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t21: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t22: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t23: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t24: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t25: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t26: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t27: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t28: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t29: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t30: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t31: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/built_in_not_dynamic_t32: MissingCompileTimeError
-Language/Expressions/Identifier_Reference/evaluation_property_extraction_t03: RuntimeError
-Language/Expressions/Identifier_Reference/evaluation_type_parameter_t01: RuntimeError
-Language/Expressions/Instance_Creation/New/evaluation_t12: RuntimeError
-Language/Expressions/Instance_Creation/New/evaluation_t19: RuntimeError
-Language/Expressions/Instance_Creation/New/evaluation_t20: RuntimeError
-Language/Expressions/Lookup/Method_Lookup/superclass_t08: RuntimeError
-Language/Expressions/Method_Invocation/Ordinary_Invocation/accessible_instance_member_t05: RuntimeError
-Language/Expressions/Method_Invocation/Ordinary_Invocation/evaluation_t07: RuntimeError
-Language/Expressions/Method_Invocation/Ordinary_Invocation/method_lookup_failed_t18: RuntimeError
-Language/Expressions/Null/instance_of_class_null_t01: Crash
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/identical_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/named_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Closurization/positional_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/deferred_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malbounded_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malbounded_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malformed_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/malformed_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/no_such_method_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/no_such_method_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/not_class_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Anonymous_Constructor_Extraction/static_type_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t01: Pass
-Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t02: Pass
-Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t03: Pass
-Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t04: Pass
-Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t05: Pass
-Language/Expressions/Property_Extraction/General_Closurization/class_object_member_t06: Pass
-Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/expression_evaluation_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t08: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/getter_lookup_t09: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/method_lookup_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/no_accessible_member_t08: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t07: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t08: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/setter_lookup_t09: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t03: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t04: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t05: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t06: CompileTimeError
-Language/Expressions/Property_Extraction/General_Closurization/static_type_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Getter_Access_and_Method_Extraction/expression_evaluation_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/identical_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/identical_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/named_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Closurization/positional_parameters_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/deferred_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malbounded_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malbounded_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malformed_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/malformed_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/no_such_method_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/no_such_method_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/not_class_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Named_Constructor_Extraction/static_type_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t05: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t06: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/getter_closurization_t08: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_named_params_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_named_params_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_positional_params_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_closurization_positional_params_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/method_identical_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_list_access_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_list_assignment_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t05: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t06: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t08: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t09: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t10: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t11: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t12: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t13: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t14: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t15: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t16: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_t17: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/operator_closurization_unary_bitwise_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t01: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t02: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t03: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t04: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t05: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t06: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t07: CompileTimeError
-Language/Expressions/Property_Extraction/Ordinary_Member_Closurization/setter_closurization_t08: CompileTimeError
-Language/Expressions/Type_Test/evaluation_t10: RuntimeError
-Language/Functions/External_Functions/not_connected_to_a_body_t01: RuntimeError
-Language/Functions/Formal_Parameters/syntax_t05: RuntimeError
-Language/Interfaces/Superinterfaces/Inheritance_and_Overriding/same_name_method_and_getter_t01: CompileTimeError
-Language/Interfaces/Superinterfaces/Inheritance_and_Overriding/same_name_method_and_getter_t02: CompileTimeError
-Language/Libraries_and_Scripts/Exports/invalid_uri_t02: Pass
-Language/Libraries_and_Scripts/Exports/syntax_t01: MissingCompileTimeError
-Language/Libraries_and_Scripts/Exports/syntax_t04: MissingCompileTimeError
-Language/Libraries_and_Scripts/Exports/syntax_t05: MissingCompileTimeError
-Language/Libraries_and_Scripts/Exports/syntax_t06: MissingCompileTimeError
-Language/Libraries_and_Scripts/Imports/deferred_import_t01: RuntimeError
-Language/Libraries_and_Scripts/Imports/deferred_import_t02: RuntimeError
-Language/Libraries_and_Scripts/Imports/invalid_uri_deferred_t01/01: MissingRuntimeError
-Language/Libraries_and_Scripts/Imports/invalid_uri_deferred_t02: CompileTimeError
-Language/Libraries_and_Scripts/Imports/invalid_uri_t02: Pass
-Language/Libraries_and_Scripts/Parts/syntax_t06: Pass
-Language/Libraries_and_Scripts/Scripts/top_level_main_t01: Crash
-Language/Libraries_and_Scripts/Scripts/top_level_main_t02: Crash
-Language/Libraries_and_Scripts/definition_syntax_t01: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t03: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t04: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t06: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t07: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t08: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t09: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t10: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t15: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t17: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t18: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t19: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t20: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t21: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t22: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t23: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t24: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t25: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t26: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t27: MissingCompileTimeError
-Language/Libraries_and_Scripts/definition_syntax_t29: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t02: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t03: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t04: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t05: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t06: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t07: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t08: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t09: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t10: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t11: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t12: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t13: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t14: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t15: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t16: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t17: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t18: MissingCompileTimeError
-Language/Libraries_and_Scripts/top_level_syntax_t19: MissingCompileTimeError
-Language/Statements/Break/label_t03: MissingCompileTimeError
-Language/Statements/Break/label_t04: MissingCompileTimeError
-Language/Statements/Continue/label_t07: MissingCompileTimeError
-Language/Statements/Labels/syntax_t03: Pass
-Language/Statements/Rethrow/execution_t04: RuntimeError
-Language/Statements/Switch/syntax_t02: Pass
-Language/Statements/Try/catch_scope_t01: RuntimeError
-Language/Statements/Yield_and_Yield_Each/Yield/execution_async_t04: Fail
-Language/Statements/Yield_and_Yield_Each/Yield/execution_async_t05: Fail
-Language/Statements/Yield_and_Yield_Each/Yield/execution_async_t06: Fail
-Language/Statements/Yield_and_Yield_Each/Yield_Each/execution_async_t01: RuntimeError
-Language/Types/Interface_Types/subtype_t44: RuntimeError
-Language/Types/Static_Types/deferred_type_t01: RuntimeError
-Language/Variables/final_or_static_initialization_t01: MissingCompileTimeError
-Language/Variables/final_or_static_initialization_t02: MissingCompileTimeError
-Language/Variables/final_or_static_initialization_t03: MissingCompileTimeError
-Language/Variables/final_t01/01: MissingRuntimeError
-Language/Variables/final_t02/01: MissingRuntimeError
-Language/Variables/final_t04: MissingCompileTimeError
-Language/Variables/final_t05: MissingCompileTimeError
-Language/Variables/final_t06: MissingCompileTimeError
-Language/Variables/final_t07: MissingCompileTimeError
 LibTest/core/StringBuffer/StringBuffer_A01_t02: RuntimeError
 LibTest/core/StringBuffer/write_A01_t02: RuntimeError
+Language/Expressions/Constants/exception_t01: Crash
+Language/Expressions/Constants/exception_t02: Crash
+Language/Expressions/Null/instance_of_class_null_t01: Crash
 
 # dartk: precompilation failures (debug)
 [ $compiler == dartkp && $runtime == dart_precompiled && $mode == debug ]
diff --git a/tests/co19/co19-runtime.status b/tests/co19/co19-runtime.status
index a0e3bc4..62b9ec17 100644
--- a/tests/co19/co19-runtime.status
+++ b/tests/co19/co19-runtime.status
@@ -3,7 +3,7 @@
 # BSD-style license that can be found in the LICENSE file.
 
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 
 # Failures ok in tests below. VM moves super initializer to end of list.
 Language/Classes/Constructors/Generative_Constructors/execution_t03: Fail, OK
@@ -38,7 +38,7 @@
 LibTest/core/Symbol/Symbol_A01_t03: RuntimeError # Issue 13596
 LibTest/core/Symbol/Symbol_A01_t05: RuntimeError # Issue 13596
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 LibTest/typed_data/Float32x4/reciprocalSqrt_A01_t01: Pass, Fail # co19 issue 599
 LibTest/typed_data/Float32x4/reciprocal_A01_t01: Pass, Fail # co19 issue 599
 # With asynchronous loading, the load errors in these tests are no longer recognized as compile errors:
@@ -46,13 +46,13 @@
 Language/Libraries_and_Scripts/Exports/invalid_uri_t02: Fail
 Language/Libraries_and_Scripts/Parts/syntax_t06: Fail
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $mode == debug ]
+[ ($runtime == vm || $runtime == dart_precompiled ) && $mode == debug ]
 LibTest/core/List/List_class_A01_t02: Pass, Slow
 
 [ ($runtime == dart_precompiled || $runtime == dart_app) && $mode == debug ]
 Language/Libraries_and_Scripts/Imports/deferred_import_t02: Crash # Issue 27201
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && ($arch != x64 && $arch != simarm64 && $arch != arm64 && $arch != simdbc64 && $arch != simdbc) ]
+[ ($runtime == vm || $runtime == dart_precompiled) && ($arch != x64 && $arch != simarm64 && $arch != arm64 && $arch != simdbc64 && $arch != simdbc) ]
 LibTest/core/int/operator_left_shift_A01_t02: Fail # co19 issue 129
 
 [ ($compiler == none || $compiler == precompiler) && ($runtime == vm || $runtime == dart_precompiled) && ($arch == mips || $arch == arm64) ]
@@ -62,7 +62,7 @@
 LibTest/collection/ListMixin/ListMixin_class_A01_t02: Skip # co19 issue 673
 LibTest/collection/ListBase/ListBase_class_A01_t02: Skip # co19 issue 673
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && ($arch == simarm || $arch == simarmv6 || $arch == simarmv5te || $arch == simmips || $arch == simarm64 || $arch == simdbc || $arch == simdbc64) ]
+[ ($runtime == vm || $runtime == dart_precompiled) && ($arch == simarm || $arch == simarmv6 || $arch == simarmv5te || $arch == simmips || $arch == simarm64 || $arch == simdbc || $arch == simdbc64) ]
 LibTest/collection/DoubleLinkedQueue/DoubleLinkedQueue_class_A01_t01: Skip  # Timeout
 LibTest/collection/IterableBase/IterableBase_class_A01_t02: Skip  # Timeout
 LibTest/collection/IterableMixin/IterableMixin_class_A02_t01: Skip  # Timeout
@@ -76,16 +76,16 @@
 LibTest/collection/ListMixin/ListMixin_class_A01_t02: Pass, Slow
 LibTest/collection/ListBase/ListBase_class_A01_t02: Pass, Slow
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 LibTest/isolate/Isolate/spawn_A02_t01: Skip # co19 issue 667
 LibTest/html/*: SkipByDesign # dart:html not supported on VM.
 LayoutTests/fast/*: SkipByDesign # DOM not supported on VM.
 WebPlatformTest/*: SkipByDesign # dart:html not supported on VM.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $mode == debug && $builder_tag == asan ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $mode == debug && $builder_tag == asan ]
 Language/Types/Interface_Types/subtype_t27: Skip  # Issue 21174.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 # co19 update Sep 29, 2015 (3ed795ea02e022ef19c77cf1b6095b7c8f5584d0)
 Language/Classes/Getters/type_object_t01: RuntimeError # Issue 23721
 Language/Classes/Getters/type_object_t02: RuntimeError # Issue 23721
@@ -155,13 +155,13 @@
 Language/Metadata/*: SkipByDesign # Uses dart:mirrors
 Language/Expressions/Null/instance_of_class_null_t01: Skip # Uses dart:mirrors
 
-[ $noopt || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit || $mode == product ]
+[ $noopt || $compiler == precompiler || $compiler == app_jit || $mode == product ]
 Language/Libraries_and_Scripts/Imports/deferred_import_t01: Skip # Eager loading
 Language/Libraries_and_Scripts/Imports/deferred_import_t02: Skip # Eager loading
 Language/Libraries_and_Scripts/Imports/invalid_uri_deferred_t01: Skip # Eager loading
 Language/Libraries_and_Scripts/Imports/invalid_uri_deferred_t02: Skip # Eager loading
 
-[ $runtime == dart_precompiled || $runtime == dart_app ]
+[ $runtime == dart_precompiled || $compiler == app_jit ]
 LibTest/isolate/Isolate/spawnUri*: SkipByDesign # Isolate.spawnUri
 
 [ $noopt || $compiler == precompiler ]
@@ -170,7 +170,7 @@
 LibTest/core/Map/Map_class_A01_t04: Pass, Timeout
 LibTest/core/Uri/encodeQueryComponent_A01_t02: Pass, Timeout
 
-[ $noopt || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit ]
+[ $noopt || $compiler == precompiler || $compiler == app_jit ]
 Language/Mixins/Mixin_Application/error_t01: Pass
 Language/Mixins/Mixin_Application/error_t02: Pass
 Language/Mixins/declaring_constructor_t01: Pass
diff --git a/tests/compiler/dart2js/enumset_test.dart b/tests/compiler/dart2js/enumset_test.dart
index 92ab39c..a5f8754 100644
--- a/tests/compiler/dart2js/enumset_test.dart
+++ b/tests/compiler/dart2js/enumset_test.dart
@@ -7,14 +7,7 @@
 import 'package:compiler/src/util/enumset.dart';
 import 'package:expect/expect.dart';
 
-enum Enum {
-  A,
-  B,
-  C,
-  D,
-  E,
-  F,
-}
+enum Enum { A, B, C, D, E, F, }
 
 main() {
   testAddRemoveContains();
diff --git a/tests/compiler/dart2js/generic_method_type_usage_test.dart b/tests/compiler/dart2js/generic_method_type_usage_test.dart
index bbaae78..9354cba 100644
--- a/tests/compiler/dart2js/generic_method_type_usage_test.dart
+++ b/tests/compiler/dart2js/generic_method_type_usage_test.dart
@@ -69,13 +69,18 @@
   aFunction<Set>();
 }
 ''',
-
   'dynamic_as_type_argument.dart': '''
 main() {
   method<dynamic>();
 }
 method<T>() {}
 ''',
+  'malformed_type_argument.dart': '''
+main() {
+  method<Unresolved>();
+}
+method<T>() {}
+''',
 };
 
 Future runTest(Uri main, {MessageKind warning, MessageKind info}) async {
@@ -114,5 +119,8 @@
         warning: MessageKind.CANNOT_INSTANTIATE_TYPE_VARIABLE);
 
     await runTest(Uri.parse('memory:dynamic_as_type_argument.dart'));
+
+    await runTest(Uri.parse('memory:malformed_type_argument.dart'),
+        warning: MessageKind.CANNOT_RESOLVE_TYPE);
   });
 }
diff --git a/tests/compiler/dart2js/kernel/assert_test.dart b/tests/compiler/dart2js/kernel/assert_test.dart
index 48c8997..700bf42 100644
--- a/tests/compiler/dart2js/kernel/assert_test.dart
+++ b/tests/compiler/dart2js/kernel/assert_test.dart
@@ -23,10 +23,9 @@
 main() {
   assert(foo(), "foo failed");
 }''';
-    return check(code,
-        extraOptions: const <String>[
-          Flags.enableCheckedMode,
-          Flags.enableAssertMessage,
-        ]);
+    return check(code, extraOptions: const <String>[
+      Flags.enableCheckedMode,
+      Flags.enableAssertMessage,
+    ]);
   });
 }
diff --git a/tests/compiler/dart2js/minimal_resolution_test.dart b/tests/compiler/dart2js/minimal_resolution_test.dart
index 4304afa..72b524b 100644
--- a/tests/compiler/dart2js/minimal_resolution_test.dart
+++ b/tests/compiler/dart2js/minimal_resolution_test.dart
@@ -26,7 +26,7 @@
   ResolutionEnqueuer enqueuer = compiler.enqueuer.resolution;
   bool isInstantiated =
       enqueuer.universe.directlyInstantiatedClasses.contains(cls);
-  bool isProcessed = enqueuer.isClassProcessed(cls);
+  bool isProcessed = enqueuer.processedClasses.contains(cls);
   Expect.equals(expected, isInstantiated,
       'Unexpected instantiation state of class $cls.');
   Expect.equals(
diff --git a/tests/compiler/dart2js/mock_compiler.dart b/tests/compiler/dart2js/mock_compiler.dart
index 7469f0c..fb5f824 100644
--- a/tests/compiler/dart2js/mock_compiler.dart
+++ b/tests/compiler/dart2js/mock_compiler.dart
@@ -290,7 +290,7 @@
   static final _emptySet = new Set();
 
   Uri translate(LibraryElement importingLibrary, Uri resolvedUri,
-          [Spannable spannable]) =>
+          Spannable spannable) =>
       resolvedUri;
   Set<Uri> get disallowedLibraryUris => _emptySet;
   bool get mockableLibraryUsed => false;
diff --git a/tests/compiler/dart2js/mock_libraries.dart b/tests/compiler/dart2js/mock_libraries.dart
index 867bf4d..501e0dc 100644
--- a/tests/compiler/dart2js/mock_libraries.dart
+++ b/tests/compiler/dart2js/mock_libraries.dart
@@ -101,6 +101,10 @@
   'Symbol': 'class Symbol { final name; const Symbol(this.name); }',
   'Type': 'class Type {}',
   'Pattern': 'abstract class Pattern {}',
+
+  '_genericNoSuchMethod': '_genericNoSuchMethod(a,b,c,d,e) {}',
+  '_unresolvedConstructorError': '_unresolvedConstructorError(a,b,c,d,e) {}',
+  '_malformedTypeError': '_malformedTypeError(message) {}',
 };
 
 const String DEFAULT_PATCH_CORE_SOURCE = r'''
diff --git a/tests/compiler/dart2js/partial_parser_test.dart b/tests/compiler/dart2js/partial_parser_test.dart
index 8cf82ae..0bc4de2 100644
--- a/tests/compiler/dart2js/partial_parser_test.dart
+++ b/tests/compiler/dart2js/partial_parser_test.dart
@@ -11,8 +11,7 @@
 }
 
 void testSkipExpression() {
-  PartialParser parser =
-      new PartialParser(new Listener());
+  PartialParser parser = new PartialParser(new Listener());
   Token token = scan('a < b;');
   token = parser.skipExpression(token);
   Expect.equals(';', token.value);
diff --git a/tests/compiler/dart2js/patch_test.dart b/tests/compiler/dart2js/patch_test.dart
index 95ee5c3..0eb0445 100644
--- a/tests/compiler/dart2js/patch_test.dart
+++ b/tests/compiler/dart2js/patch_test.dart
@@ -166,6 +166,59 @@
       "Unexpected patch metadata: ${patch.metadata}.");
 }
 
+Future testPatchFunctionGeneric() async {
+  var compiler = await applyPatch(
+      "external T test<T>();", "@patch T test<T>() { return null; } ");
+  Element origin = ensure(
+      compiler, "test", compiler.commonElements.coreLibrary.find,
+      expectIsPatched: true, checkHasBody: true);
+  ensure(compiler, "test", compiler.commonElements.coreLibrary.patch.find,
+      expectIsPatch: true, checkHasBody: true);
+  compiler.resolver.resolve(origin);
+
+  DiagnosticCollector collector = compiler.diagnosticCollector;
+  Expect.isTrue(
+      collector.warnings.isEmpty, "Unexpected warnings: ${collector.warnings}");
+  Expect.isTrue(
+      collector.errors.isEmpty, "Unexpected errors: ${collector.errors}");
+}
+
+Future testPatchFunctionGenericExtraTypeVariable() async {
+  var compiler = await applyPatch(
+      "external T test<T>();", "@patch T test<T, S>() { return null; } ");
+  Element origin = ensure(
+      compiler, "test", compiler.commonElements.coreLibrary.find,
+      expectIsPatched: true, checkHasBody: true);
+  ensure(compiler, "test", compiler.commonElements.coreLibrary.patch.find,
+      expectIsPatch: true, checkHasBody: true);
+  compiler.resolver.resolve(origin);
+
+  DiagnosticCollector collector = compiler.diagnosticCollector;
+  Expect.isTrue(
+      collector.warnings.isEmpty, "Unexpected warnings: ${collector.warnings}");
+  Expect.equals(1, collector.errors.length);
+  Expect.isTrue(collector.errors.first.message.kind ==
+      MessageKind.PATCH_TYPE_VARIABLES_MISMATCH);
+}
+
+Future testPatchFunctionGenericDifferentNames() async {
+  var compiler = await applyPatch(
+      "external T test<T, S>();", "@patch T test<S, T>() { return null; } ");
+  Element origin = ensure(
+      compiler, "test", compiler.commonElements.coreLibrary.find,
+      expectIsPatched: true, checkHasBody: true);
+  ensure(compiler, "test", compiler.commonElements.coreLibrary.patch.find,
+      expectIsPatch: true, checkHasBody: true);
+  compiler.resolver.resolve(origin);
+
+  DiagnosticCollector collector = compiler.diagnosticCollector;
+  Expect.isTrue(
+      collector.warnings.isEmpty, "Unexpected warnings: ${collector.warnings}");
+  Expect.equals(1, collector.errors.length);
+  Expect.isTrue(collector.errors.first.message.kind ==
+      MessageKind.PATCH_TYPE_VARIABLES_MISMATCH);
+}
+
 Future testPatchVersioned() async {
   String fullPatch = "test(){return 'string';}";
   String lazyPatch = "test(){return 'new and improved string';}";
@@ -1086,6 +1139,9 @@
     await testPatchRedirectingConstructor();
     await testPatchFunction();
     await testPatchFunctionMetadata();
+    await testPatchFunctionGeneric();
+    await testPatchFunctionGenericExtraTypeVariable();
+    await testPatchFunctionGenericDifferentNames();
     await testPatchMember();
     await testPatchGetter();
     await testRegularMember();
diff --git a/tests/corelib/corelib.status b/tests/corelib/corelib.status
index 48cfb52..2dfdb3b 100644
--- a/tests/corelib/corelib.status
+++ b/tests/corelib/corelib.status
@@ -14,7 +14,7 @@
 string_from_environment3_test: Skip
 string_from_environment_test: Skip
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) ]
+[ $compiler == none || $compiler == precompiler || $compiler == app_jit ]
 unicode_test: Fail        # Bug 6706
 compare_to2_test: Fail    # Bug 4018
 
@@ -30,7 +30,7 @@
 string_case_test/01: Fail # Bug 18061
 
 # #void should be a valid symbol.
-[ $compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit || $compiler == dart2js ]
+[ $compiler == none || $compiler == precompiler || $compiler == app_jit || $compiler == dart2js ]
 symbol_reserved_word_test/02: CompileTimeError # bug 20191
 symbol_reserved_word_test/05: CompileTimeError # bug 20191
 
@@ -61,7 +61,7 @@
 [ $compiler == dart2js && $fast_startup ]
 apply3_test: Fail # mirrors not supported
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && $runtime != dartium && $runtime != drt ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && $runtime != dartium && $runtime != drt ]
 symbol_test/02: MissingCompileTimeError # bug 11669
 symbol_test/03: MissingCompileTimeError # bug 11669
 
@@ -122,6 +122,8 @@
 
 [ $compiler == dart2js && ($runtime == ff || $runtime == jsshell) ]
 string_case_test/01: Fail, OK  # Bug in Firefox.
+list_test/none: Fail # Issue 28014
+list_test/01: Fail # Issue 28014
 
 [ $compiler == dart2js && $runtime == dartium ]
 string_case_test/02: Fail, OK  # Bug in dartium version of V8.
@@ -156,10 +158,10 @@
 # The regexp tests are not verified to work on non d8/vm platforms yet.
 regexp/*: Skip
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 regexp/global_test: Skip # Timeout. Issue 21709 and 21708
 
-[ $runtime != vm && $runtime != dart_precompiled && $runtime != dart_app && $compiler != dart2analyzer]
+[ $runtime != vm && $runtime != dart_precompiled && $compiler != dart2analyzer]
 data_resource_test: RuntimeError # Issue 23825 (not implemented yet).
 file_resource_test: Skip, OK # VM specific test, uses dart:io.
 http_resource_test: Skip, OK # VM specific test, uses dart:io.
@@ -170,7 +172,7 @@
 [ $mode == debug ]
 regexp/pcre_test: Pass, Slow # Timeout. Issue 22008
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $arch == simarmv5te ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $arch == simarmv5te ]
 int_parse_radix_test/*: Pass, Slow
 big_integer_parsed_mul_div_vm_test: Pass, Slow
 
@@ -199,7 +201,7 @@
 big_integer_parsed_mul_div_vm_test: Pass, Timeout # --no_intrinsify
 int_parse_radix_test: Pass, Timeout # --no_intrinsify
 
-[ $compiler == precompiler || $runtime == dart_app ]
+[ $compiler == precompiler || $compiler == app_jit ]
 data_resource_test: Skip # Resolve URI not supported yet in product mode.
 package_resource_test: Skip # Resolve URI not supported yet in product mode.
 file_resource_test: Skip # Resolve URI not supported yet in product mode.
diff --git a/tests/html/html.status b/tests/html/html.status
index b3aece5..23ec5b1 100644
--- a/tests/html/html.status
+++ b/tests/html/html.status
@@ -82,6 +82,9 @@
 fileapi_test/entry: Fail # TODO(dart2js-team): Please triage this failure.
 fileapi_test/getDirectory: Fail # TODO(dart2js-team): Please triage this failure.
 fileapi_test/getFile: Fail # TODO(dart2js-team): Please triage this failure.
+media_stream_test/supported_MediaStreamEvent: RuntimeError # Please triage.
+media_stream_test/supported_MediaStreamTrackEvent: RuntimeError # Please triage.
+speechrecognition_test/types: RuntimeError # Please triage.
 
 [ $compiler == dart2js && $runtime == chromeOnAndroid ]
 crypto_test/functional: Pass, Slow # TODO(dart2js-team): Please triage this failure.
@@ -353,7 +356,7 @@
 
 # 'html' tests import the HTML library, so they only make sense in
 # a browser environment.
-[ $runtime == vm || $runtime == dart_precompiled || $runtime == dart_app ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 *: Skip
 
 [ $compiler == dart2js && ($runtime == drt || $runtime == ff) ]
diff --git a/tests/isolate/isolate.status b/tests/isolate/isolate.status
index 8274317..038396b 100644
--- a/tests/isolate/isolate.status
+++ b/tests/isolate/isolate.status
@@ -2,17 +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.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 browser/*: SkipByDesign  # Browser specific tests
 isolate_stress_test: Skip # Issue 12588: Uses dart:html. This should be able to pass when we have wrapper-less tests.
 
-[ $runtime != vm || $mode == product ]
+[ $runtime != vm || $mode == product || $compiler == app_jit ]
 checked_test: Skip # Unsupported.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $arch == mips && $mode == debug ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $arch == mips && $mode == debug ]
 mandel_isolate_test: Skip # Uses 600 MB Ram on our 1 GB test device.
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) ]
+[ $compiler == none || $compiler == precompiler || $compiler == app_jit ]
 compile_time_error_test/01: Skip # Issue 12587
 ping_test: Skip           # Resolve test issues
 ping_pause_test: Skip     # Resolve test issues
@@ -89,7 +89,7 @@
 
 [ $csp ]
 deferred_in_isolate2_test: Skip # Issue 16898. Deferred loading does not work from an isolate in CSP-mode
-browser/package_resolve_browser_hook_test: RuntimeError # CSP violation. Issue 27914
+browser/package_resolve_browser_hook_test: SkipByDesign # Test written in a way that violates CSP.
 
 [ $compiler == dart2js && $runtime == chromeOnAndroid ]
 isolate_stress_test: Pass, Slow # TODO(kasperl): Please triage.
@@ -191,7 +191,7 @@
 static_function_test: SkipByDesign
 unresolved_ports_test: SkipByDesign
 
-[ $runtime == dart_precompiled || $runtime == dart_app ]
+[ $runtime == dart_precompiled || $compiler == app_jit ]
 count_test: Skip # Isolate.spawnUri
 cross_isolate_message_test: Skip # Isolate.spawnUri
 deferred_in_isolate2_test: Skip # Isolate.spawnUri
diff --git a/tests/language/initializing_formal_access_test.dart b/tests/language/initializing_formal_access_test.dart
index 71f445e..79ce73f 100644
--- a/tests/language/initializing_formal_access_test.dart
+++ b/tests/language/initializing_formal_access_test.dart
@@ -1,9 +1,6 @@
 // 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.
-//
-// DartOptions=--initializing-formal-access
-// VMOptions=--initializing-formal-access
 
 import "package:expect/expect.dart";
 
diff --git a/tests/language/initializing_formal_capture_test.dart b/tests/language/initializing_formal_capture_test.dart
index 8257d4f..3fd2d2c 100644
--- a/tests/language/initializing_formal_capture_test.dart
+++ b/tests/language/initializing_formal_capture_test.dart
@@ -1,9 +1,6 @@
 // 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.
-//
-// DartOptions=--initializing-formal-access
-// VMOptions=--initializing-formal-access
 
 import "package:expect/expect.dart";
 
diff --git a/tests/language/initializing_formal_final_test.dart b/tests/language/initializing_formal_final_test.dart
index 3df4ba5..9cda9fe 100644
--- a/tests/language/initializing_formal_final_test.dart
+++ b/tests/language/initializing_formal_final_test.dart
@@ -1,9 +1,6 @@
 // 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.
-//
-// DartOptions=--initializing-formal-access
-// VMOptions=--initializing-formal-access
 
 import "package:expect/expect.dart";
 
diff --git a/tests/language/initializing_formal_promotion_test.dart b/tests/language/initializing_formal_promotion_test.dart
index 89ec79e..822d2d21 100644
--- a/tests/language/initializing_formal_promotion_test.dart
+++ b/tests/language/initializing_formal_promotion_test.dart
@@ -1,9 +1,6 @@
 // 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.
-//
-// DartOptions=--initializing-formal-access
-// VMOptions=--initializing-formal-access
 
 import "package:expect/expect.dart";
 
diff --git a/tests/language/initializing_formal_scope_test.dart b/tests/language/initializing_formal_scope_test.dart
index 5544a8e..f75308f 100644
--- a/tests/language/initializing_formal_scope_test.dart
+++ b/tests/language/initializing_formal_scope_test.dart
@@ -1,9 +1,6 @@
 // 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.
-//
-// DartOptions=--initializing-formal-access
-// VMOptions=--initializing-formal-access
 
 import "package:expect/expect.dart";
 
diff --git a/tests/language/initializing_formal_type_test.dart b/tests/language/initializing_formal_type_test.dart
index af44444..5f3134c 100644
--- a/tests/language/initializing_formal_type_test.dart
+++ b/tests/language/initializing_formal_type_test.dart
@@ -1,9 +1,6 @@
 // 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.
-//
-// DartOptions=--initializing-formal-access
-// VMOptions=--initializing-formal-access
 
 import "package:expect/expect.dart";
 
diff --git a/tests/language/language.status b/tests/language/language.status
index c0489a5..371db4d 100644
--- a/tests/language/language.status
+++ b/tests/language/language.status
@@ -5,7 +5,7 @@
 # This directory contains tests that are intended to show the
 # current state of the language.
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) ]
+[ $compiler == none || $compiler == precompiler || $compiler == app_jit ]
 tearoff_constructor_basic_test: Skip # Crashes in checked mode -- hausner investigating
 generic_methods_type_expression_test: RuntimeError # Issue 25869
 
@@ -51,7 +51,7 @@
 # Fails because `as T` is an error rather than being treated like `as dynamic`.
 generic_methods_type_expression_test: RuntimeError # Issue 27460
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && $checked ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && $checked ]
 # These generic functions tests pass for the wrong reason in checked mode,
 # because the parsed type parameters are mapped to dynamic type.
 generic_methods_function_type_test: Pass # Issue 25869
@@ -61,17 +61,17 @@
 generic_functions_test: Pass # Issue 25869
 generic_methods_generic_function_parameter_test: Pass # Issue 25869
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && ($runtime == vm || $runtime == dart_precompiled) ]
 
 class_keyword_test/02: MissingCompileTimeError # Issue 13627
 unicode_bom_test: Fail # Issue 16067
 vm/debug_break_enabled_vm_test/01: Crash, OK # Expected to hit breakpoint.
 try_catch_optimized1_test: Skip # Srdjan investigating
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && $checked ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && $checked ]
 type_variable_bounds4_test/01: Fail # Issue 14006
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && (($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) || $runtime == drt || $runtime == dartium) ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && (($runtime == vm || $runtime == dart_precompiled) || $runtime == drt || $runtime == dartium) ]
 dynamic_prefix_core_test/none: Fail # Issue 12478
 export_ambiguous_main_negative_test: Fail # Issue 14763
 
@@ -130,16 +130,16 @@
 [ $compiler == none && $runtime == drt ]
 disassemble_test: Pass, Fail # Issue 18122
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $arch == mips && $mode == debug ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $arch == mips && $mode == debug ]
 large_class_declaration_test: SkipSlow # Times out. Issue 20352
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $arch == arm64 ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $arch == arm64 ]
 large_class_declaration_test: SkipSlow # Uses too much memory.
 
 [ $compiler == none && ($runtime == dartium || $runtime == drt) && $mode == debug ]
 large_class_declaration_test: SkipSlow # Times out. Issue 20352
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && ( $arch == simarm || $arch == arm || $arch == simarmv6 || $arch == armv6 || $arch == simarmv5te || $arch == armv5te || $arch == simarm64 || $arch == arm64 || $arch == simmips || $arch == mips) ]
+[ ($runtime == vm || $runtime == dart_precompiled) && ( $arch == simarm || $arch == arm || $arch == simarmv6 || $arch == armv6 || $arch == simarmv5te || $arch == armv5te || $arch == simarm64 || $arch == arm64 || $arch == simmips || $arch == mips) ]
 vm/load_to_load_unaligned_forwarding_vm_test: Pass, Crash # Unaligned offset. Issue 22151
 vm/unaligned_float_access_literal_index_test: Pass, Crash # Unaligned offset. Issue 22151
 vm/unaligned_float_access_literal_index_test: Pass, Crash # Unaligned offset. Issue 22151
@@ -148,7 +148,7 @@
 [ $compiler == none && ($runtime == dartium || $runtime == drt) ]
 issue23244_test: Fail # Issue 23244
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && (($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) || $runtime == drt || $runtime == dartium) && $arch == ia32 ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && (($runtime == vm || $runtime == dart_precompiled) || $runtime == drt || $runtime == dartium) && $arch == ia32 ]
 vm/regress_24517_test: Pass, Fail # Issue 24517.
 
 [ $compiler == precompiler && $runtime == dart_precompiled ]
@@ -201,7 +201,7 @@
 deferred_not_loaded_check_test: Fail
 vm/regress_27201_test: Fail
 
-[ $mode == product || $compiler == dart2appjit || $compiler == dart2app || $compiler == precompiler ]
+[ $mode == product || $compiler == app_jit || $compiler == precompiler ]
 # Deferred loading happens eagerly. Issue #27587
 regress_23408_test: Fail
 deferred_inheritance_constraints_test/redirecting_constructor: Fail
@@ -217,7 +217,7 @@
 deferred_global_test: Fail
 vm/regress_27201_test: Fail
 
-[ $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit ]
+[ $compiler == precompiler || $compiler == app_jit ]
 ct_const2_test: Skip # Incompatible flag: --compile_all
 hello_dart_test: Skip # Incompatible flag: --compile_all
 
@@ -225,7 +225,7 @@
 implicit_closure_test: Skip # Incompatible flag: --use_slow_path
 deopt_inlined_function_lazy_test: Skip # Incompatible flag: --deoptimize-alot
 
-[ $noopt || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit ]
+[ $noopt || $compiler == precompiler || $compiler == app_jit ]
 vm/type_vm_test: RuntimeError # Expects line and column numbers
 vm/type_cast_vm_test: RuntimeError # Expects line and column numbers
 
@@ -245,17 +245,17 @@
 vm/type_vm_test: Fail,OK  # Expects exact type name.
 
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && $browser ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && $browser ]
 # The following tests are supposed to fail.
 library_env_test/has_io_support: RuntimeError, OK
 library_env_test/has_no_html_support: RuntimeError, OK
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && $browser != true ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && $browser != true ]
 # The following tests are supposed to fail.
 library_env_test/has_html_support: RuntimeError, OK
 library_env_test/has_no_io_support: RuntimeError, OK
 
-[ ($compiler == none || $compiler == dart2app || $compiler == dart2appjit) && $noopt == false && $mode != product ]
+[ ($compiler == none || $compiler == app_jit) && $noopt == false && $mode != product ]
 # The following tests are supposed to fail.
 library_env_test/has_no_mirror_support: RuntimeError, OK
 
diff --git a/tests/language/language_analyzer2.status b/tests/language/language_analyzer2.status
index 72203db..d13f27a 100644
--- a/tests/language/language_analyzer2.status
+++ b/tests/language/language_analyzer2.status
@@ -156,9 +156,6 @@
 # test issue 14228
 black_listed_test/none: fail # test issue 14228, warnings are required but not expected
 
-# test issue 14410, "typedef C = " is now really illegal syntax
-mixin_illegal_syntax_test/none: fail
-
 # test issue 14736, It is a static warning if a class C declares an instance method named n and has a setter named n=.
 setter4_test: StaticWarning
 
@@ -292,7 +289,6 @@
 method_override6_test: StaticWarning
 method_override_test: StaticWarning
 mixin_illegal_static_access_test: StaticWarning
-mixin_illegal_syntax_test/13: CompileTimeError
 mixin_type_parameters_mixin_extends_test: StaticWarning
 mixin_type_parameters_mixin_test: StaticWarning
 mixin_type_parameters_super_extends_test: StaticWarning
diff --git a/tests/language/language_dart2js.status b/tests/language/language_dart2js.status
index 4d5379c..8c73613 100644
--- a/tests/language/language_dart2js.status
+++ b/tests/language/language_dart2js.status
@@ -24,6 +24,7 @@
 mixin_supertype_subclass3_test: CompileTimeError # Issue 23773
 mixin_supertype_subclass4_test: CompileTimeError # Issue 23773
 mixin_of_mixin_test: CompileTimeError # Issue 23773
+mixin_illegal_syntax_test/00: MissingCompileTimeError # Issue 14410
 
 # The following tests are supposed to fail.
 # In testing-mode, dart2js supports all dart:X libraries (because it
diff --git a/tests/language/language_kernel.status b/tests/language/language_kernel.status
index b5cc7b3..f2569e9 100644
--- a/tests/language/language_kernel.status
+++ b/tests/language/language_kernel.status
@@ -3,13 +3,170 @@
 # BSD-style license that can be found in the LICENSE file.
 
 # These tests currently take too long. Remove when they are fixed.
-[ $compiler == dartk || $compiler == rasta ]
+[ $compiler == dartk ]
 large_class_declaration_test: Skip
 large_implicit_getter_test: Skip
 larger_implicit_getter_test: Skip
 
+###############################################################################
+# Dartk Entries
+###############################################################################
+
+[ $compiler == dartk || $compiler == dartkp ]
+bad_constructor_test/05: DartkCompileTimeError
+conditional_import_string_test: DartkCompileTimeError
+conditional_import_test: DartkCompileTimeError
+conflicting_type_variable_and_setter_test: DartkCompileTimeError
+const_for_in_variable_test/01: DartkMissingCompileTimeError
+constructor_duplicate_final_test/03: DartkMissingCompileTimeError
+deep_nesting1_negative_test: DartkCrash
+deep_nesting2_negative_test: DartkCrash
+deferred_closurize_load_library_test: DartkCrash
+enum_syntax_test/06: DartkMissingCompileTimeError
+export_double_same_main_test: DartkCrash
+export_main_test: DartkCrash
+external_test/21: DartkMissingCompileTimeError
+external_test/24: DartkMissingCompileTimeError
+external_test/25: DartkMissingCompileTimeError
+final_syntax_test/01: DartkMissingCompileTimeError
+final_syntax_test/02: DartkMissingCompileTimeError
+final_syntax_test/03: DartkMissingCompileTimeError
+final_syntax_test/04: DartkMissingCompileTimeError
+main_not_a_function_test/01: DartkCrash
+metadata_test: DartkCompileTimeError
+mixin_illegal_super_use_test/01: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/02: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/03: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/04: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/05: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/06: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/07: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/08: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/09: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/10: DartkMissingCompileTimeError
+mixin_illegal_super_use_test/11: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/01: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/02: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/03: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/04: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/05: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/06: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/07: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/08: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/09: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/10: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/11: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/12: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/13: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/14: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/15: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/16: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/17: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/18: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/19: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/20: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/21: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/22: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/23: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/24: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/25: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/26: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/27: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/28: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/29: DartkMissingCompileTimeError
+mixin_illegal_superclass_test/30: DartkMissingCompileTimeError
+multiline_newline_test/01: DartkCompileTimeError
+multiline_newline_test/02: DartkCompileTimeError
+multiline_newline_test/03: DartkCompileTimeError
+multiline_newline_test/04: DartkMissingCompileTimeError
+multiline_newline_test/05: DartkMissingCompileTimeError
+multiline_newline_test/06: DartkMissingCompileTimeError
+no_main_test/01: DartkCrash
+not_enough_positional_arguments_test/01: DartkCompileTimeError
+regress_27617_test/1: DartkMissingCompileTimeError
+super_call3_test/01: DartkCrash
+tearoff_basic_test: DartkCompileTimeError
+tearoff_constructor_basic_test: DartkCompileTimeError
+type_variable_conflict2_test/02: DartkMissingCompileTimeError
+vm/debug_break_enabled_vm_test/01: DartkCompileTimeError
+vm/debug_break_enabled_vm_test/none: DartkCompileTimeError
+vm/reflect_core_vm_test: DartkCompileTimeError
+vm/regress_27201_test: DartkCompileTimeError
+
 # dartk: JIT failures
 [ $compiler == dartk && $runtime == vm ]
+enum_syntax_test/05: DartkMissingCompileTimeError
+reify_typevar_static_test/00: DartkMissingCompileTimeError
+type_variable_conflict2_test/06: DartkMissingCompileTimeError
+type_variable_conflict2_test/08: DartkMissingCompileTimeError
+type_variable_conflict2_test/10: DartkMissingCompileTimeError
+
+# dartk: precompilation failures
+[ $compiler == dartkp && $runtime == dart_precompiled ]
+const_for_in_variable_test/01: MissingCompileTimeError
+constructor_duplicate_final_test/03: MissingCompileTimeError
+enum_syntax_test/06: MissingCompileTimeError
+external_test/21: MissingCompileTimeError
+external_test/24: MissingCompileTimeError
+external_test/25: MissingCompileTimeError
+final_syntax_test/01: MissingCompileTimeError
+final_syntax_test/02: MissingCompileTimeError
+final_syntax_test/03: MissingCompileTimeError
+final_syntax_test/04: MissingCompileTimeError
+mixin_illegal_superclass_test/01: MissingCompileTimeError
+mixin_illegal_superclass_test/02: MissingCompileTimeError
+mixin_illegal_superclass_test/03: MissingCompileTimeError
+mixin_illegal_superclass_test/04: MissingCompileTimeError
+mixin_illegal_superclass_test/05: MissingCompileTimeError
+mixin_illegal_superclass_test/06: MissingCompileTimeError
+mixin_illegal_superclass_test/07: MissingCompileTimeError
+mixin_illegal_superclass_test/08: MissingCompileTimeError
+mixin_illegal_superclass_test/09: MissingCompileTimeError
+mixin_illegal_superclass_test/10: MissingCompileTimeError
+mixin_illegal_superclass_test/11: MissingCompileTimeError
+mixin_illegal_superclass_test/12: MissingCompileTimeError
+mixin_illegal_superclass_test/13: MissingCompileTimeError
+mixin_illegal_superclass_test/14: MissingCompileTimeError
+mixin_illegal_superclass_test/15: MissingCompileTimeError
+mixin_illegal_superclass_test/16: MissingCompileTimeError
+mixin_illegal_superclass_test/17: MissingCompileTimeError
+mixin_illegal_superclass_test/18: MissingCompileTimeError
+mixin_illegal_superclass_test/19: MissingCompileTimeError
+mixin_illegal_superclass_test/20: MissingCompileTimeError
+mixin_illegal_superclass_test/21: MissingCompileTimeError
+mixin_illegal_superclass_test/22: MissingCompileTimeError
+mixin_illegal_superclass_test/23: MissingCompileTimeError
+mixin_illegal_superclass_test/24: MissingCompileTimeError
+mixin_illegal_superclass_test/25: MissingCompileTimeError
+mixin_illegal_superclass_test/26: MissingCompileTimeError
+mixin_illegal_superclass_test/27: MissingCompileTimeError
+mixin_illegal_superclass_test/28: MissingCompileTimeError
+mixin_illegal_superclass_test/29: MissingCompileTimeError
+mixin_illegal_superclass_test/30: MissingCompileTimeError
+mixin_illegal_super_use_test/01: MissingCompileTimeError
+mixin_illegal_super_use_test/02: MissingCompileTimeError
+mixin_illegal_super_use_test/03: MissingCompileTimeError
+mixin_illegal_super_use_test/04: MissingCompileTimeError
+mixin_illegal_super_use_test/05: MissingCompileTimeError
+mixin_illegal_super_use_test/06: MissingCompileTimeError
+mixin_illegal_super_use_test/07: MissingCompileTimeError
+mixin_illegal_super_use_test/08: MissingCompileTimeError
+mixin_illegal_super_use_test/09: MissingCompileTimeError
+mixin_illegal_super_use_test/10: MissingCompileTimeError
+mixin_illegal_super_use_test/11: MissingCompileTimeError
+multiline_newline_test/04: MissingCompileTimeError
+multiline_newline_test/05: MissingCompileTimeError
+multiline_newline_test/06: MissingCompileTimeError
+regress_27617_test/1: MissingCompileTimeError
+type_variable_conflict2_test/02: MissingCompileTimeError
+
+
+###############################################################################
+# VM Entries
+###############################################################################
+
+# dartk: Shared JIT & Precompilation failures
+[ ($compiler == dartk && $runtime == vm) || ($compiler == dartkp && $runtime == dart_precompiled) ]
 accessor_conflict_export2_test: RuntimeError
 accessor_conflict_export_test: RuntimeError
 accessor_conflict_import2_test: RuntimeError
@@ -28,7 +185,6 @@
 asyncstar_throw_in_catch_test: Timeout
 asyncstar_yield_test: Timeout
 asyncstar_yieldstar_test: Timeout
-bad_constructor_test/05: CompileTimeError
 bad_raw_string_negative_test: Fail
 cha_deopt1_test: RuntimeError
 cha_deopt2_test: RuntimeError
@@ -41,26 +197,17 @@
 compile_time_constant_k_test/03: RuntimeError
 compile_time_constant_o_test/01: RuntimeError
 compile_time_constant_o_test/02: RuntimeError
-conditional_import_string_test: CompileTimeError
-conditional_import_test: CompileTimeError
 config_import_test: RuntimeError
-conflicting_type_variable_and_setter_test: CompileTimeError
 const_dynamic_type_literal_test/02: RuntimeError
 const_error_multiply_initialized_test/02: RuntimeError
 const_error_multiply_initialized_test/04: RuntimeError
-const_evaluation_test/01: RuntimeError
-const_for_in_variable_test/01: MissingCompileTimeError
-const_locals_test: RuntimeError
 const_nested_test: RuntimeError
-const_string_test: RuntimeError
 constructor2_test: RuntimeError
 constructor3_test: RuntimeError
 constructor5_test: RuntimeError
 constructor6_test: RuntimeError
 constructor_duplicate_final_test/01: MissingRuntimeError
 constructor_duplicate_final_test/02: MissingRuntimeError
-constructor_duplicate_final_test/03: MissingCompileTimeError
-constructor_named_arguments_test/01: Crash
 custom_await_stack_trace_test: RuntimeError
 cyclic_type2_test: CompileTimeError
 cyclic_type_test/00: RuntimeError
@@ -73,10 +220,7 @@
 cyclic_type_variable_test/03: Crash
 cyclic_type_variable_test/04: Crash
 cyclic_type_variable_test/none: Crash
-deep_nesting1_negative_test: Crash
-deep_nesting2_negative_test: Crash
 deferred_call_empty_before_load_test: RuntimeError
-deferred_closurize_load_library_test: Crash
 deferred_constant_list_test: RuntimeError
 deferred_constraints_constants_test/none: RuntimeError
 deferred_constraints_constants_test/reference_after_load: RuntimeError
@@ -129,26 +273,15 @@
 enum_private_test/01: RuntimeError
 enum_private_test/02: RuntimeError
 enum_private_test/none: RuntimeError
-enum_syntax_test/05: MissingCompileTimeError
-enum_syntax_test/06: MissingCompileTimeError
 enum_test: RuntimeError
 evaluation_redirecting_constructor_test: RuntimeError
 example_constructor_test: RuntimeError
-export_double_same_main_test: Crash
-export_main_test: Crash
 external_test/10: MissingRuntimeError
 external_test/13: MissingRuntimeError
 external_test/20: MissingRuntimeError
-external_test/21: MissingCompileTimeError
-external_test/24: MissingCompileTimeError
-external_test/25: MissingCompileTimeError
 f_bounded_equality_test: RuntimeError
 field_initialization_order_test: RuntimeError
 final_field_initialization_order_test: RuntimeError
-final_syntax_test/01: MissingCompileTimeError
-final_syntax_test/02: MissingCompileTimeError
-final_syntax_test/03: MissingCompileTimeError
-final_syntax_test/04: MissingCompileTimeError
 fixed_type_variable2_test/02: RuntimeError
 fixed_type_variable2_test/04: RuntimeError
 fixed_type_variable2_test/06: RuntimeError
@@ -190,7 +323,6 @@
 getter_setter_in_lib_test: RuntimeError
 inferrer_closure_test: RuntimeError
 initializing_formal_final_test: RuntimeError
-instance_creation_in_function_annotation_test: RuntimeError
 is_not_class2_test: RuntimeError
 issue13474_test: RuntimeError
 issue_1751477_test: RuntimeError
@@ -209,59 +341,13 @@
 least_upper_bound_expansive_test/none: CompileTimeError
 library_env_test/has_html_support: RuntimeError
 library_env_test/has_no_io_support: RuntimeError
-library_env_test/has_no_mirror_support: RuntimeError
 list_literal4_test: RuntimeError
-main_not_a_function_test/01: Crash
 malformed_test/none: RuntimeError
 map_literal3_test: RuntimeError
 map_literal4_test: RuntimeError
 map_literal6_test: RuntimeError
-metadata_test: CompileTimeError
 method_override_test: RuntimeError
 mixin_generic_test: RuntimeError
-mixin_illegal_super_use_test/01: MissingCompileTimeError
-mixin_illegal_super_use_test/02: MissingCompileTimeError
-mixin_illegal_super_use_test/03: MissingCompileTimeError
-mixin_illegal_super_use_test/04: MissingCompileTimeError
-mixin_illegal_super_use_test/05: MissingCompileTimeError
-mixin_illegal_super_use_test/06: MissingCompileTimeError
-mixin_illegal_super_use_test/07: MissingCompileTimeError
-mixin_illegal_super_use_test/08: MissingCompileTimeError
-mixin_illegal_super_use_test/09: MissingCompileTimeError
-mixin_illegal_super_use_test/10: MissingCompileTimeError
-mixin_illegal_super_use_test/11: MissingCompileTimeError
-mixin_illegal_superclass_test/01: MissingCompileTimeError
-mixin_illegal_superclass_test/02: MissingCompileTimeError
-mixin_illegal_superclass_test/03: MissingCompileTimeError
-mixin_illegal_superclass_test/04: MissingCompileTimeError
-mixin_illegal_superclass_test/05: MissingCompileTimeError
-mixin_illegal_superclass_test/06: MissingCompileTimeError
-mixin_illegal_superclass_test/07: MissingCompileTimeError
-mixin_illegal_superclass_test/08: MissingCompileTimeError
-mixin_illegal_superclass_test/09: MissingCompileTimeError
-mixin_illegal_superclass_test/10: MissingCompileTimeError
-mixin_illegal_superclass_test/11: MissingCompileTimeError
-mixin_illegal_superclass_test/12: MissingCompileTimeError
-mixin_illegal_superclass_test/13: MissingCompileTimeError
-mixin_illegal_superclass_test/14: MissingCompileTimeError
-mixin_illegal_superclass_test/15: MissingCompileTimeError
-mixin_illegal_superclass_test/16: MissingCompileTimeError
-mixin_illegal_superclass_test/17: MissingCompileTimeError
-mixin_illegal_superclass_test/18: MissingCompileTimeError
-mixin_illegal_superclass_test/19: MissingCompileTimeError
-mixin_illegal_superclass_test/20: MissingCompileTimeError
-mixin_illegal_superclass_test/21: MissingCompileTimeError
-mixin_illegal_superclass_test/22: MissingCompileTimeError
-mixin_illegal_superclass_test/23: MissingCompileTimeError
-mixin_illegal_superclass_test/24: MissingCompileTimeError
-mixin_illegal_superclass_test/25: MissingCompileTimeError
-mixin_illegal_superclass_test/26: MissingCompileTimeError
-mixin_illegal_superclass_test/27: MissingCompileTimeError
-mixin_illegal_superclass_test/28: MissingCompileTimeError
-mixin_illegal_superclass_test/29: MissingCompileTimeError
-mixin_illegal_superclass_test/30: MissingCompileTimeError
-mixin_illegal_syntax_test/13: CompileTimeError
-mixin_illegal_syntax_test/none: CompileTimeError
 mixin_mixin2_test: RuntimeError
 mixin_mixin3_test: RuntimeError
 mixin_mixin4_test: RuntimeError
@@ -272,18 +358,10 @@
 mixin_type_parameters_simple_test: RuntimeError
 mixin_type_parameters_super_extends_test: RuntimeError
 mixin_type_parameters_super_test: RuntimeError
-multiline_newline_test/01: CompileTimeError
-multiline_newline_test/02: CompileTimeError
-multiline_newline_test/03: CompileTimeError
-multiline_newline_test/04: MissingCompileTimeError
-multiline_newline_test/05: MissingCompileTimeError
-multiline_newline_test/06: MissingCompileTimeError
 multiline_newline_test/none: RuntimeError
 named_parameters_type_test/01: MissingRuntimeError
 named_parameters_type_test/02: MissingRuntimeError
 named_parameters_type_test/03: MissingRuntimeError
-no_main_test/01: Crash
-not_enough_positional_arguments_test/01: CompileTimeError
 not_enough_positional_arguments_test/02: MissingRuntimeError
 not_enough_positional_arguments_test/05: MissingRuntimeError
 null_test/none: RuntimeError
@@ -293,384 +371,74 @@
 prefix10_negative_test: Fail
 prefix21_test: RuntimeError
 redirecting_constructor_initializer_test: RuntimeError
-redirecting_factory_reflection_test: RuntimeError
 regress_18713_test: RuntimeError
 regress_22443_test: RuntimeError
 regress_22700_test: RuntimeError
 regress_23408_test: RuntimeError
 regress_27164_test: CompileTimeError
-regress_27617_test/1: MissingCompileTimeError
 regress_r24720_test: RuntimeError
-reify_typevar_static_test/00: MissingCompileTimeError
 reify_typevar_test: RuntimeError
 script1_negative_test: Fail
 script2_negative_test: Fail
 setter_no_getter_call_test/none: RuntimeError
 static_setter_get_test/01: RuntimeError
-super_call3_test/01: Crash
 super_test: RuntimeError
 switch7_negative_test: Fail
 switch_try_catch_test: RuntimeError
 sync_generator3_test/test2: RuntimeError
-tearoff_basic_test: CompileTimeError
-tearoff_constructor_basic_test: CompileTimeError
 try_catch_on_syntax_test/10: MissingRuntimeError
 try_catch_on_syntax_test/11: MissingRuntimeError
 try_finally_regress_25654_test: RuntimeError
 type_checks_in_factory_method_test: RuntimeError
 type_parameter_literal_test: RuntimeError
-type_variable_conflict2_test/02: MissingCompileTimeError
-type_variable_conflict2_test/06: MissingCompileTimeError
-type_variable_conflict2_test/08: MissingCompileTimeError
-type_variable_conflict2_test/10: MissingCompileTimeError
 type_variable_function_type_test: RuntimeError
-vm/debug_break_enabled_vm_test/01: CompileTimeError
-vm/debug_break_enabled_vm_test/none: CompileTimeError
-vm/reflect_core_vm_test: CompileTimeError
 vm/type_cast_vm_test: RuntimeError
 vm/type_vm_test: RuntimeError
 
+# dartk: JIT failures
+[ $compiler == dartk && $runtime == vm ]
+const_evaluation_test/01: RuntimeError
+const_locals_test: RuntimeError
+constructor_named_arguments_test/01: Crash
+const_string_test: RuntimeError
+instance_creation_in_function_annotation_test: RuntimeError
+library_env_test/has_no_mirror_support: RuntimeError
+redirecting_factory_reflection_test: RuntimeError
+
 # dartk: JIT failures (debug)
 [ $compiler == dartk && $runtime == vm && $mode == debug ]
 async_star_regression_fisk_test: Crash  # Stack mismatch during expression translation.
 async_star_test: Crash  # Stack mismatch during expression translation.
+generic_sends_test: Crash
 issue23244_test: Crash  # Class finalization issue
-not_enough_positional_arguments_test/02: Crash  # Crash
-not_enough_positional_arguments_test/05: Crash  # Crash
+not_enough_positional_arguments_test/02: Crash
+not_enough_positional_arguments_test/05: Crash
 vm/optimized_guarded_field_isolates_test: Crash  # Class finalization issue
-generic_sends_test: Crash  # Crash
 
 # dartk: precompilation failures
 [ $compiler == dartkp && $runtime == dart_precompiled ]
-accessor_conflict_export2_test: RuntimeError
-accessor_conflict_export_test: RuntimeError
-accessor_conflict_import2_test: RuntimeError
-accessor_conflict_import_prefixed2_test: RuntimeError
-accessor_conflict_import_prefixed_test: RuntimeError
-accessor_conflict_import_test: RuntimeError
-assertion_test: RuntimeError
-async_await_test: RuntimeError
-async_star_cancel_and_throw_in_finally_test: RuntimeError
-async_star_cancel_while_paused_test: RuntimeError
-async_star_pause_test: RuntimeError
-async_star_regression_fisk_test: Timeout
-async_star_stream_take_test: Timeout
-async_star_take_reyield_test: Timeout
-async_star_test: Timeout
-asyncstar_throw_in_catch_test: Timeout
-asyncstar_yield_test: Timeout
-asyncstar_yieldstar_test: Timeout
-bad_constructor_test/05: CompileTimeError
-bad_raw_string_negative_test: Fail
-cha_deopt1_test: RuntimeError
-cha_deopt2_test: RuntimeError
-cha_deopt3_test: RuntimeError
-closure_type_variable_test: RuntimeError
-closures_initializer_test: RuntimeError
-compile_time_constant12_test: Crash
-compile_time_constant_k_test/01: RuntimeError
-compile_time_constant_k_test/02: RuntimeError
-compile_time_constant_k_test/03: RuntimeError
-compile_time_constant_o_test/01: RuntimeError
-compile_time_constant_o_test/02: RuntimeError
-conditional_import_string_test: CompileTimeError
-conditional_import_test: CompileTimeError
-config_import_test: RuntimeError
-conflicting_type_variable_and_setter_test: CompileTimeError
-const_dynamic_type_literal_test/02: RuntimeError
-const_error_multiply_initialized_test/02: RuntimeError
-const_error_multiply_initialized_test/04: RuntimeError
 const_evaluation_test/01: Crash
-const_for_in_variable_test/01: MissingCompileTimeError
-const_nested_test: RuntimeError
-constructor2_test: RuntimeError
-constructor3_test: RuntimeError
-constructor5_test: RuntimeError
-constructor6_test: RuntimeError
-constructor_duplicate_final_test/01: MissingRuntimeError
-constructor_duplicate_final_test/02: MissingRuntimeError
-constructor_duplicate_final_test/03: MissingCompileTimeError
-custom_await_stack_trace_test: RuntimeError
-cyclic_type2_test: CompileTimeError
-cyclic_type_test/00: RuntimeError
-cyclic_type_test/01: RuntimeError
-cyclic_type_test/02: CompileTimeError
-cyclic_type_test/03: RuntimeError
-cyclic_type_test/04: CompileTimeError
-cyclic_type_variable_test/01: Crash
-cyclic_type_variable_test/02: Crash
-cyclic_type_variable_test/03: Crash
-cyclic_type_variable_test/04: Crash
-cyclic_type_variable_test/none: Crash
-deep_nesting1_negative_test: Crash
-deep_nesting2_negative_test: Crash
-deferred_call_empty_before_load_test: RuntimeError
-deferred_closurize_load_library_test: Crash
-deferred_constant_list_test: RuntimeError
-deferred_constraints_constants_test/none: RuntimeError
-deferred_constraints_constants_test/reference_after_load: RuntimeError
-deferred_constraints_type_annotation_test/as_operation: RuntimeError
-deferred_constraints_type_annotation_test/catch_check: RuntimeError
-deferred_constraints_type_annotation_test/is_check: RuntimeError
-deferred_constraints_type_annotation_test/new: RuntimeError
-deferred_constraints_type_annotation_test/new_before_load: RuntimeError
-deferred_constraints_type_annotation_test/new_generic1: RuntimeError
-deferred_constraints_type_annotation_test/new_generic2: RuntimeError
-deferred_constraints_type_annotation_test/new_generic3: RuntimeError
-deferred_constraints_type_annotation_test/none: RuntimeError
-deferred_constraints_type_annotation_test/static_method: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation1: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation_generic1: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation_generic2: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation_generic3: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation_generic4: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation_non_deferred: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation_null: RuntimeError
-deferred_constraints_type_annotation_test/type_annotation_top_level: RuntimeError
-deferred_function_type_test: RuntimeError
-deferred_global_test: RuntimeError
-deferred_import_core_test: RuntimeError
-deferred_inheritance_constraints_test/redirecting_constructor: RuntimeError
-deferred_inlined_test: RuntimeError
-deferred_load_constants_test/none: RuntimeError
-deferred_load_inval_code_test: RuntimeError
-deferred_load_library_wrong_args_test/none: RuntimeError
-deferred_mixin_test: RuntimeError
-deferred_no_such_method_test: RuntimeError
-deferred_not_loaded_check_test: RuntimeError
-deferred_only_constant_test: RuntimeError
-deferred_optimized_test: RuntimeError
-deferred_redirecting_factory_test: RuntimeError
-deferred_regression_22995_test: RuntimeError
-deferred_shadow_load_library_test: RuntimeError
-deferred_shared_and_unshared_classes_test: RuntimeError
-deferred_static_seperate_test: RuntimeError
-deferred_super_dependency_test/01: RuntimeError
-deferred_type_dependency_test/as: RuntimeError
-deferred_type_dependency_test/is: RuntimeError
-deferred_type_dependency_test/none: RuntimeError
-deferred_type_dependency_test/type_annotation: RuntimeError
-duplicate_export_negative_test: Fail
-enum_duplicate_test/01: RuntimeError
-enum_duplicate_test/02: RuntimeError
-enum_duplicate_test/none: RuntimeError
-enum_mirror_test: RuntimeError
-enum_private_test/01: RuntimeError
-enum_private_test/02: RuntimeError
-enum_private_test/none: RuntimeError
-enum_syntax_test/06: MissingCompileTimeError
-enum_test: RuntimeError
-evaluation_redirecting_constructor_test: RuntimeError
-example_constructor_test: RuntimeError
-export_double_same_main_test: Crash
-export_main_test: Crash
-external_test/10: MissingRuntimeError
-external_test/13: MissingRuntimeError
-external_test/20: MissingRuntimeError
-external_test/21: MissingCompileTimeError
-external_test/24: MissingCompileTimeError
-external_test/25: MissingCompileTimeError
-f_bounded_equality_test: RuntimeError
-field_initialization_order_test: RuntimeError
-final_field_initialization_order_test: RuntimeError
-final_syntax_test/01: MissingCompileTimeError
-final_syntax_test/02: MissingCompileTimeError
-final_syntax_test/03: MissingCompileTimeError
-final_syntax_test/04: MissingCompileTimeError
-fixed_type_variable2_test/02: RuntimeError
-fixed_type_variable2_test/04: RuntimeError
-fixed_type_variable2_test/06: RuntimeError
-fixed_type_variable_test/01: RuntimeError
-fixed_type_variable_test/02: RuntimeError
-fixed_type_variable_test/03: RuntimeError
-fixed_type_variable_test/04: RuntimeError
-fixed_type_variable_test/05: RuntimeError
-fixed_type_variable_test/06: RuntimeError
-for2_test: RuntimeError
-for_variable_capture_test: RuntimeError
 full_stacktrace1_test: RuntimeError
 full_stacktrace2_test: RuntimeError
 full_stacktrace3_test: RuntimeError
-function_subtype2_test: RuntimeError
-function_subtype_bound_closure3_test: RuntimeError
-function_subtype_bound_closure4_test: RuntimeError
-function_subtype_cast1_test: RuntimeError
-function_subtype_inline0_test: RuntimeError
-function_subtype_local3_test: RuntimeError
-function_subtype_local4_test: RuntimeError
-function_subtype_not1_test: RuntimeError
-function_type_alias2_test: RuntimeError
-function_type_alias3_test: RuntimeError
-function_type_alias4_test: RuntimeError
-generic2_test: RuntimeError
-generic_closure_test: RuntimeError
-generic_creation_test: RuntimeError
-generic_field_mixin2_test: RuntimeError
-generic_field_mixin4_test: RuntimeError
-generic_field_mixin5_test: RuntimeError
-generic_functions_test: Crash
-generic_inheritance_test: RuntimeError
-generic_local_functions_test: Crash
-generic_methods_function_type_test: Crash
-generic_methods_generic_function_parameter_test: Crash
-generic_methods_new_test: Crash
-generic_methods_test: Crash
-generic_methods_type_expression_test: Crash
-generic_test: RuntimeError
-getter_closure_execution_order_test: RuntimeError
-getter_setter_in_lib_test: RuntimeError
 if_null_assignment_static_test/35: Crash
-inferrer_closure_test: RuntimeError
-initializing_formal_final_test: RuntimeError
 instance_creation_in_function_annotation_test: Crash
 invocation_mirror_invoke_on2_test: Crash
-is_not_class2_test: RuntimeError
-issue13474_test: RuntimeError
 issue21079_test: Crash
-issue_1751477_test: RuntimeError
 large_class_declaration_test: Timeout
-least_upper_bound_expansive_test/01: CompileTimeError
-least_upper_bound_expansive_test/02: CompileTimeError
-least_upper_bound_expansive_test/03: CompileTimeError
-least_upper_bound_expansive_test/04: CompileTimeError
-least_upper_bound_expansive_test/05: CompileTimeError
-least_upper_bound_expansive_test/06: CompileTimeError
-least_upper_bound_expansive_test/07: CompileTimeError
-least_upper_bound_expansive_test/08: CompileTimeError
-least_upper_bound_expansive_test/09: CompileTimeError
-least_upper_bound_expansive_test/10: CompileTimeError
-least_upper_bound_expansive_test/11: CompileTimeError
-least_upper_bound_expansive_test/12: CompileTimeError
-least_upper_bound_expansive_test/none: CompileTimeError
-library_env_test/has_html_support: RuntimeError
 library_env_test/has_mirror_support: RuntimeError
-library_env_test/has_no_io_support: RuntimeError
-list_literal4_test: RuntimeError
-main_not_a_function_test/01: Crash
-malformed_test/none: RuntimeError
-map_literal3_test: RuntimeError
-map_literal4_test: RuntimeError
-map_literal6_test: RuntimeError
-metadata_test: CompileTimeError
-method_override_test: RuntimeError
-mixin_generic_test: RuntimeError
-mixin_illegal_super_use_test/01: MissingCompileTimeError
-mixin_illegal_super_use_test/02: MissingCompileTimeError
-mixin_illegal_super_use_test/03: MissingCompileTimeError
-mixin_illegal_super_use_test/04: MissingCompileTimeError
-mixin_illegal_super_use_test/05: MissingCompileTimeError
-mixin_illegal_super_use_test/06: MissingCompileTimeError
-mixin_illegal_super_use_test/07: MissingCompileTimeError
-mixin_illegal_super_use_test/08: MissingCompileTimeError
-mixin_illegal_super_use_test/09: MissingCompileTimeError
-mixin_illegal_super_use_test/10: MissingCompileTimeError
-mixin_illegal_super_use_test/11: MissingCompileTimeError
-mixin_illegal_superclass_test/01: MissingCompileTimeError
-mixin_illegal_superclass_test/02: MissingCompileTimeError
-mixin_illegal_superclass_test/03: MissingCompileTimeError
-mixin_illegal_superclass_test/04: MissingCompileTimeError
-mixin_illegal_superclass_test/05: MissingCompileTimeError
-mixin_illegal_superclass_test/06: MissingCompileTimeError
-mixin_illegal_superclass_test/07: MissingCompileTimeError
-mixin_illegal_superclass_test/08: MissingCompileTimeError
-mixin_illegal_superclass_test/09: MissingCompileTimeError
-mixin_illegal_superclass_test/10: MissingCompileTimeError
-mixin_illegal_superclass_test/11: MissingCompileTimeError
-mixin_illegal_superclass_test/12: MissingCompileTimeError
-mixin_illegal_superclass_test/13: MissingCompileTimeError
-mixin_illegal_superclass_test/14: MissingCompileTimeError
-mixin_illegal_superclass_test/15: MissingCompileTimeError
-mixin_illegal_superclass_test/16: MissingCompileTimeError
-mixin_illegal_superclass_test/17: MissingCompileTimeError
-mixin_illegal_superclass_test/18: MissingCompileTimeError
-mixin_illegal_superclass_test/19: MissingCompileTimeError
-mixin_illegal_superclass_test/20: MissingCompileTimeError
-mixin_illegal_superclass_test/21: MissingCompileTimeError
-mixin_illegal_superclass_test/22: MissingCompileTimeError
-mixin_illegal_superclass_test/23: MissingCompileTimeError
-mixin_illegal_superclass_test/24: MissingCompileTimeError
-mixin_illegal_superclass_test/25: MissingCompileTimeError
-mixin_illegal_superclass_test/26: MissingCompileTimeError
-mixin_illegal_superclass_test/27: MissingCompileTimeError
-mixin_illegal_superclass_test/28: MissingCompileTimeError
-mixin_illegal_superclass_test/29: MissingCompileTimeError
-mixin_illegal_superclass_test/30: MissingCompileTimeError
-mixin_illegal_syntax_test/13: CompileTimeError
-mixin_illegal_syntax_test/none: CompileTimeError
-mixin_mixin2_test: RuntimeError
-mixin_mixin3_test: RuntimeError
-mixin_mixin4_test: RuntimeError
-mixin_mixin5_test: RuntimeError
-mixin_mixin_bound2_test: RuntimeError
-mixin_mixin_bound_test: RuntimeError
-mixin_super_test: RuntimeError
-mixin_type_parameters_simple_test: RuntimeError
-mixin_type_parameters_super_extends_test: RuntimeError
-mixin_type_parameters_super_test: RuntimeError
-multiline_newline_test/01: CompileTimeError
-multiline_newline_test/02: CompileTimeError
-multiline_newline_test/03: CompileTimeError
-multiline_newline_test/04: MissingCompileTimeError
-multiline_newline_test/05: MissingCompileTimeError
-multiline_newline_test/06: MissingCompileTimeError
-multiline_newline_test/none: RuntimeError
-named_parameters_type_test/01: MissingRuntimeError
-named_parameters_type_test/02: MissingRuntimeError
-named_parameters_type_test/03: MissingRuntimeError
-no_main_test/01: Crash
-not_enough_positional_arguments_test/01: CompileTimeError
-not_enough_positional_arguments_test/02: MissingRuntimeError
-not_enough_positional_arguments_test/05: MissingRuntimeError
-null_test/none: RuntimeError
-number_identifier_test/05: RuntimeError
-positional_parameters_type_test/01: MissingRuntimeError
-positional_parameters_type_test/02: MissingRuntimeError
-prefix10_negative_test: Fail
-prefix21_test: RuntimeError
-redirecting_constructor_initializer_test: RuntimeError
 redirecting_factory_reflection_test: Crash
 regress_18535_test: Crash
-regress_18713_test: RuntimeError
-regress_22443_test: RuntimeError
-regress_22700_test: RuntimeError
-regress_23408_test: RuntimeError
-regress_27164_test: CompileTimeError
-regress_27617_test/1: MissingCompileTimeError
-regress_r24720_test: RuntimeError
-reify_typevar_test: RuntimeError
-script1_negative_test: Fail
-script2_negative_test: Fail
-setter_no_getter_call_test/none: RuntimeError
-stack_trace_test: RuntimeError
 stacktrace_rethrow_error_test/none: RuntimeError
 stacktrace_rethrow_error_test/withtraceparameter: RuntimeError
 stacktrace_rethrow_nonerror_test: RuntimeError
-static_setter_get_test/01: RuntimeError
+stack_trace_test: RuntimeError
 string_interpolation7_test: RuntimeError
-super_call3_test/01: Crash
 super_call4_test: RuntimeError
-super_test: RuntimeError
-switch7_negative_test: Fail
-switch_try_catch_test: RuntimeError
-sync_generator3_test/test2: RuntimeError
-tearoff_basic_test: CompileTimeError
-tearoff_constructor_basic_test: CompileTimeError
-try_catch_on_syntax_test/10: MissingRuntimeError
-try_catch_on_syntax_test/11: MissingRuntimeError
-try_finally_regress_25654_test: RuntimeError
-type_checks_in_factory_method_test: RuntimeError
-type_parameter_literal_test: RuntimeError
-type_variable_conflict2_test/02: MissingCompileTimeError
-type_variable_function_type_test: RuntimeError
-vm/debug_break_enabled_vm_test/01: CompileTimeError
-vm/debug_break_enabled_vm_test/none: CompileTimeError
-vm/reflect_core_vm_test: CompileTimeError
-vm/type_cast_vm_test: RuntimeError
-vm/type_vm_test: RuntimeError
 
 # dartk: precompilation failures (debug)
 [ $compiler == dartkp && $runtime == dart_precompiled && $mode == debug ]
 constructor_named_arguments_test/01: Crash
-enum_syntax_test/05: Crash
 generic_sends_test: Crash
 not_enough_positional_arguments_test/05: Crash
+enum_syntax_test/05: Crash
diff --git a/tests/language/mixin_illegal_syntax_test.dart b/tests/language/mixin_illegal_syntax_test.dart
index c9bb069..167304d 100644
--- a/tests/language/mixin_illegal_syntax_test.dart
+++ b/tests/language/mixin_illegal_syntax_test.dart
@@ -6,8 +6,9 @@
 class G<T> { }
 class M { }
 
-typedef T0 = abstract S with M;
-abstract class T0A = S with M;
+class T = S with M;
+typedef T0 = S with M;         /// 00: compile-time error
+abstract class TA = S with M;
 class T1 = final S with M;     /// 01: compile-time error
 class T2 = var S with M;       /// 02: compile-time error
 class T3 = const S with M;     /// 03: compile-time error
@@ -29,13 +30,13 @@
     implements M  /// 12: compile-time error
     implements M { }
 
-class D1 extends T0 { }
+class D1 extends T { }
 
 class X = S;   /// 14: compile-time error
 
 main() {
-  new T0();  /// 13: static type warning, runtime error
-  new T0A();  /// 13: static type warning, runtime error
+  new T();
+  new TA();  /// 13: static type warning, runtime error
   new T1();  /// 01: continued
   new T2();  /// 02: continued
   new T3();  /// 03: continued
diff --git a/tests/language/mixin_proto_test.dart b/tests/language/mixin_proto_test.dart
new file mode 100644
index 0000000..e195d90
--- /dev/null
+++ b/tests/language/mixin_proto_test.dart
@@ -0,0 +1,36 @@
+// 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.
+
+// Tests that a program in csp mode doesn't access the prototype chain
+// on platforms that don't support direct access to __proto__.
+// This test is most useful with --csp and on a platform that doesn't support
+// __proto__ access (such as Rhino).
+// See http://dartbug.com/27290 .
+
+import 'package:expect/expect.dart';
+
+class A {
+  var x;
+  foo() => 44;
+  bar() => 22;
+}
+
+class B {
+  var y;
+  foo() => 42;
+}
+
+class C extends A with B {
+  var z;
+  bar() => 499;
+}
+
+main() {
+  var all = [new A(), new B(), new C()];
+  Expect.equals(44, all[0].foo());
+  Expect.equals(22, all[0].bar());
+  Expect.equals(42, all[1].foo());
+  Expect.equals(42, all[2].foo());
+  Expect.equals(499, all[2].bar());
+}
\ No newline at end of file
diff --git a/tests/language/parameter_initializer5_test.dart b/tests/language/parameter_initializer5_test.dart
index eb7208d..0e93202 100644
--- a/tests/language/parameter_initializer5_test.dart
+++ b/tests/language/parameter_initializer5_test.dart
@@ -1,9 +1,6 @@
 // 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
 // BSD-style license that can be found in the LICENSE file.
-//
-// DartOptions=--initializing-formal-access
-// VMOptions=--initializing-formal-access
 
 // Use the this.x parameter in an initializer expression.
 
diff --git a/tests/lib/lib.status b/tests/lib/lib.status
index 2a84f7b..2e7457f 100644
--- a/tests/lib/lib.status
+++ b/tests/lib/lib.status
@@ -209,14 +209,11 @@
 
 # 'js' tests import the dart:js library, so they only make sense in
 # a browser environment.
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 js/*: Skip
 
-# 'js' tests import the dart:js library, so they only make sense in
-# a browser environment.
-[ $runtime == dart_app ]
-js/*: SkipByDesign
-mirrors/*: SkipByDesign
+[ $compiler == app_jit ]
+mirrors/*: Skip # Issue 27929: Triage
 
 [ $compiler == dart2js && $minified ]
 mirrors/mirrors_used_get_name_test: RuntimeError
@@ -255,13 +252,13 @@
 [ $runtime == vm ]
 convert/streamed_conversion_json_utf8_decode_test: Pass, Slow # Infrequent timeouts.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 async/timer_not_available_test: Fail, OK
 mirrors/native_class_test: Fail, OK # This test is meant to run in a browser.
 mirrors/deferred_type_test: CompileTimeError, OK # Don't have a multitest marker for dynamic compile time errors.
 mirrors/initializing_formals_test/01: Fail # initializing formals are implicitly final as of Dart 1.21
 
-[ $compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit ]
+[ $compiler == none || $compiler == precompiler || $compiler == app_jit ]
 async/timer_not_available_test: SkipByDesign # only meant to test when there is no way to implement timer (currently only in d8)
 
 mirrors/symbol_validation_test: RuntimeError # Issue 13596
@@ -331,7 +328,7 @@
 [ $compiler == dart2js && $mode == debug ]
 mirrors/native_class_test: Pass, Slow
 
-[ ($compiler == none || $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit) && $arch == mips ]
+[ ($compiler == none || $compiler == precompiler || $compiler == app_jit) && $arch == mips ]
 async/timer_regress22626_test: Pass, RuntimeError # Issue 22626
 
 [ $arch == simarm || $arch == simarmv6 || $arch == simarmv5te ]
@@ -354,13 +351,13 @@
 [ $mode == debug && $arch == ia32 && $system == windows ]
 convert/streamed_conversion_json_utf8_decode_test: Skip  # Verification OOM.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $mode == debug && $arch == x64 && $system == windows ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $mode == debug && $arch == x64 && $system == windows ]
 convert/streamed_conversion_json_utf8_decode_test: Pass, Slow
 
 [ $mode == debug && $arch != ia32 && $arch != x64 && $arch != simarm && $arch != simarmv6 && $arch != simarmv5te ]
 convert/streamed_conversion_json_utf8_decode_test: Skip  # Verification not yet implemented.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $mode == debug && $builder_tag == asan ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $mode == debug && $builder_tag == asan ]
 mirrors/immutable_collections_test: SkipSlow  # Timeout.
 convert/streamed_conversion_json_utf8_decode_test: Skip  # Timeout.
 
diff --git a/tests/standalone/io/socket_bind_test.dart b/tests/standalone/io/socket_bind_test.dart
index f701f0c..08963eb 100644
--- a/tests/standalone/io/socket_bind_test.dart
+++ b/tests/standalone/io/socket_bind_test.dart
@@ -4,11 +4,12 @@
 
 import 'dart:async';
 import 'dart:io';
-import 'dart:convert';
 
 import 'package:async_helper/async_helper.dart';
 import 'package:expect/expect.dart';
 
+import 'test_utils.dart' show freeIPv4AndIPv6Port, retry;
+
 testBindShared(String host, bool v6Only) {
   asyncStart();
   ServerSocket.bind(
@@ -112,27 +113,6 @@
   asyncEnd();
 }
 
-Future<int> freeIPv4AndIPv6Port() async {
-  var socket =
-    await ServerSocket.bind(InternetAddress.ANY_IP_V6, 0, v6Only: false);
-  int port = socket.port;
-  await socket.close();
-  return port;
-}
-
-Future retry(Future fun(), {int maxCount: 10}) async {
-  for (int i = 0; i < maxCount; i++) {
-    try {
-      // If there is no exception this will simply return, otherwise we keep
-      // trying.
-      return await fun();
-    } catch (_) {}
-    print("Failed to execute test closure in attempt $i "
-          "(${maxCount - i} retries left).");
-  }
-  return await fun();
-}
-
 main() async {
   asyncStart();
 
diff --git a/tests/standalone/io/socket_source_address_test.dart b/tests/standalone/io/socket_source_address_test.dart
index 64dc490..8f076ed 100644
--- a/tests/standalone/io/socket_source_address_test.dart
+++ b/tests/standalone/io/socket_source_address_test.dart
@@ -9,6 +9,8 @@
 import "package:async_helper/async_helper.dart";
 import "package:expect/expect.dart";
 
+import 'test_utils.dart' show freeIPv4AndIPv6Port, retry;
+
 Future throws(Function f, Function check) async {
   try {
     await f();
@@ -23,9 +25,12 @@
 }
 
 Future testArguments(connectFunction) async {
+  int freePort = await freeIPv4AndIPv6Port();
+
   var sourceAddress;
   asyncStart();
-  var server = await ServerSocket.bind(InternetAddress.LOOPBACK_IP_V4, 0);
+  var server = await ServerSocket.bind(InternetAddress.LOOPBACK_IP_V4,
+                                       freePort);
   server.listen((_) {
     throw 'Unexpected connection from address $sourceAddress';
   }, onDone: () => asyncEnd());
@@ -73,6 +78,8 @@
                    bool v6Only,
                    Function connectFunction,
                    Function closeDestroyFunction) async {
+  int freePort = await freeIPv4AndIPv6Port();
+
   var successCount = 0;
   if (!v6Only) successCount += ipV4SourceAddresses.length;
   if (bindAddress.type == InternetAddressType.IP_V6) {
@@ -83,7 +90,7 @@
   if (successCount == 0) allConnected.complete();
 
   asyncStart();
-  var server = await ServerSocket.bind(bindAddress, 0, v6Only: v6Only);
+  var server = await ServerSocket.bind(bindAddress, freePort, v6Only: v6Only);
   server.listen((s) {
     s.destroy();
     count++;
@@ -130,19 +137,40 @@
   asyncEnd();
 }
 
-main() {
-  testArguments(RawSocket.connect);
-  testArguments(Socket.connect);
-  testConnect(
-      InternetAddress.ANY_IP_V4, false, RawSocket.connect, (s) => s.close());
-  testConnect(
-      InternetAddress.ANY_IP_V4, false, Socket.connect, (s) => s.destroy());
-  testConnect(
-      InternetAddress.ANY_IP_V6, false, RawSocket.connect, (s) => s.close());
-  testConnect(
-      InternetAddress.ANY_IP_V6, false, Socket.connect, (s) => s.destroy());
-  testConnect(
-      InternetAddress.ANY_IP_V6, true, RawSocket.connect, (s) => s.close());
-  testConnect(
-      InternetAddress.ANY_IP_V6, true, Socket.connect, (s) => s.destroy());
+main() async {
+  asyncStart();
+
+  await retry(() async {
+    await testArguments(RawSocket.connect);
+  });
+  await retry(() async {
+    await testArguments(Socket.connect);
+  });
+
+  await retry(() async {
+    await testConnect(
+        InternetAddress.ANY_IP_V4, false, RawSocket.connect, (s) => s.close());
+  });
+  await retry(() async {
+    await testConnect(
+        InternetAddress.ANY_IP_V4, false, Socket.connect, (s) => s.destroy());
+  });
+  await retry(() async {
+    await testConnect(
+        InternetAddress.ANY_IP_V6, false, RawSocket.connect, (s) => s.close());
+  });
+  await retry(() async {
+    await testConnect(
+        InternetAddress.ANY_IP_V6, false, Socket.connect, (s) => s.destroy());
+  });
+  await retry(() async {
+    await testConnect(
+        InternetAddress.ANY_IP_V6, true, RawSocket.connect, (s) => s.close());
+  });
+  await retry(() async {
+    await testConnect(
+        InternetAddress.ANY_IP_V6, true, Socket.connect, (s) => s.destroy());
+  });
+
+  asyncEnd();
 }
diff --git a/tests/standalone/io/test_utils.dart b/tests/standalone/io/test_utils.dart
new file mode 100644
index 0000000..2dbaf97
--- /dev/null
+++ b/tests/standalone/io/test_utils.dart
@@ -0,0 +1,28 @@
+// 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.
+
+import 'dart:async';
+import 'dart:io';
+
+Future<int> freeIPv4AndIPv6Port() async {
+  var socket =
+    await ServerSocket.bind(InternetAddress.ANY_IP_V6, 0, v6Only: false);
+  int port = socket.port;
+  await socket.close();
+  return port;
+}
+
+Future retry(Future fun(), {int maxCount: 10}) async {
+  for (int i = 0; i < maxCount; i++) {
+    try {
+      // If there is no exception this will simply return, otherwise we keep
+      // trying.
+      return await fun();
+    } catch (_) {}
+    print("Failed to execute test closure in attempt $i "
+          "(${maxCount - i} retries left).");
+  }
+  return await fun();
+}
+
diff --git a/tests/standalone/standalone.status b/tests/standalone/standalone.status
index dfc31c0..0a29025 100644
--- a/tests/standalone/standalone.status
+++ b/tests/standalone/standalone.status
@@ -19,16 +19,16 @@
 
 issue14236_test: Pass # Do not remove this line. It serves as a marker for Issue 14516 comment #4.
 
-[ ($runtime != vm && $runtime != dart_precompiled && $runtime != dart_app) && ($runtime != drt || $compiler != none)) ]
+[ ($runtime != vm && $runtime != dart_precompiled) && ($runtime != drt || $compiler != none)) ]
 no_assert_test: Fail, OK # This is testing a vm flag.
 env_test: Skip # This is testing a vm command line parsing scenario.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 package/package_isolate_test: Fail # Issue 12474
 io/observatory_test: Fail
 package/scenarios/invalid/same_package_twice_test: Pass # Issue 24119
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $checked ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $checked ]
 # These tests have type errors on purpose.
 io/process_invalid_arguments_test: Fail, OK
 io/directory_invalid_arguments_test: Fail, OK
@@ -41,7 +41,7 @@
 io/file_fuzz_test: Skip
 io/directory_fuzz_test: Skip
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $system == macos ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $system == macos ]
 # This test fails with "Too many open files" on the Mac OS buildbot.
 # This is expected as MacOS by default runs with a very low number
 # of allowed open files ('ulimit -n' says something like 256).
@@ -114,7 +114,7 @@
 [ $compiler == dart2js && $cps_ir && $checked ]
 *: Skip # `assert` not implemented
 
-[ ($runtime == vm || $runtime == dart_app) && ($arch == arm || $arch == arm64) ]
+[ $runtime == vm && ($arch == arm || $arch == arm64) ]
 io/file_stream_test: Skip # Issue 26109
 io/file_typed_data_test: Skip # Issue 26109
 io/file_input_stream_test: Skip # Issue 26109
@@ -197,12 +197,12 @@
 io/sleep_test: Pass, Fail # Issue 25757
 io/socket_info_ipv6_test: RuntimeError # Issue 27876
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) && $mode == debug && $builder_tag == asan ]
+[ ($runtime == vm || $runtime == dart_precompiled) && $mode == debug && $builder_tag == asan ]
 io/file_lock_test: Skip  # Timeout.
 io/test_runner_test: Skip  # Timeout.
 io/http_client_stays_alive_test: Skip  # Timeout.
 
-[ ($runtime == vm || $runtime == dart_precompiled || $runtime == dart_app) ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 # Failures in secure networking while NSS is replaced with BoringSSL
 io/https_client_certificate_test: RuntimeError # Issue 24070
 io/secure_socket_renegotiate_test: RuntimeError
@@ -220,10 +220,10 @@
 map_insert_remove_oom_test: Skip # Heap limit too low. Increasing iteration count to make a higher limit a meaningful test makes it too slow for simarm[64] bots.
 io/web_socket_test: Pass, RuntimeError # Issue 24674
 
-[ $compiler == precompiler || $compiler == dart2app || $compiler == dart2appjit ]
+[ $compiler == precompiler || $compiler == app_jit ]
 io/compile_all_test: Skip # Incompatible flag --compile_all
 
-[ $runtime == dart_app ]
+[ $compiler == app_jit ]
 io/stdout_bad_argument_test: Skip # Test exits and so can't generate snapshot.
 io/directory_list_sync_test: Skip # Snapshot path differs from script path.
 io/test_extension_test: Skip # Snapshot path differs from script path.
@@ -276,7 +276,10 @@
 io/test_harness_analyzer_test: CompileTimeError # Imports dart:mirrors
 io/test_runner_test: CompileTimeError # Imports dart:mirrors
 
-[ $runtime == dart_precompiled || $runtime == dart_app || $mode == product ]
+[ $compiler == app_jit ]
+assert_test: RuntimeError # Script name change?
+
+[ $runtime == dart_precompiled || $mode == product ]
 assert_test: SkipByDesign # Requires checked mode.
 no_assert_test: SkipByDesign # Requires checked mode.
 io/code_collection_test: Skip # Incompatible flags
@@ -293,7 +296,7 @@
 io/stdio_implicit_close_test: Skip # SkipByDesign
 
 # Following tests are skipped on dart_app as package mapping is not supported.
-[ $runtime == dart_precompiled || $runtime == dart_app ]
+[ $runtime == dart_precompiled || $compiler == app_jit ]
 package/scenarios/packages_file_strange_formatting/mixed_line_ends_test: Skip
 package/scenarios/packages_file_strange_formatting/empty_lines_test: Skip
 package/scenarios/invalid/invalid_utf8_test: Skip
@@ -342,7 +345,7 @@
 io/https_bad_certificate_test: RuntimeError
 io/secure_server_closing_test: RuntimeError
 
-[ $runtime == vm || $runtime == dart_app || $runtime == dart_precompiled ]
+[ $runtime == vm || $runtime == dart_precompiled ]
 deferred_transitive_import_error_test: Skip # Contains intentional errors.
 
 [ $hot_reload || $hot_reload_rollback ]
diff --git a/third_party/firefox_jsshell/README.google b/third_party/firefox_jsshell/README.google
index 7868748..8a02b18 100644
--- a/third_party/firefox_jsshell/README.google
+++ b/third_party/firefox_jsshell/README.google
@@ -1,8 +1,8 @@
 Name: Firefox command line javascript shell.
 Short Name: js-shell
-URL: http://ftp.mozilla.org/pub/firefox/candidates/47.0-candidates/build2/
-Version: JavaScript-C47
-Date: June 3, 2016
+URL: http://ftp.mozilla.org/pub/firefox/candidates/50.0-candidates/build2/
+Version: JavaScript-C50
+Date: December 6, 2016
 License: MPL, http://www.mozilla.org/MPL
 
 Description:
diff --git a/third_party/firefox_jsshell/linux/jsshell.tar.gz.sha1 b/third_party/firefox_jsshell/linux/jsshell.tar.gz.sha1
index 1348fe9..4262db5 100644
--- a/third_party/firefox_jsshell/linux/jsshell.tar.gz.sha1
+++ b/third_party/firefox_jsshell/linux/jsshell.tar.gz.sha1
@@ -1 +1 @@
-f44ede84757b76c86bc6dc8aee8f24699390623f
\ No newline at end of file
+4b9a595ea8d8eb1932d6f291010cfbd71dfa0061
\ No newline at end of file
diff --git a/third_party/firefox_jsshell/mac/jsshell.tar.gz.sha1 b/third_party/firefox_jsshell/mac/jsshell.tar.gz.sha1
index 952f5cc..f172154 100644
--- a/third_party/firefox_jsshell/mac/jsshell.tar.gz.sha1
+++ b/third_party/firefox_jsshell/mac/jsshell.tar.gz.sha1
@@ -1 +1 @@
-3d866ec4efe98698381671b25940b8ed1926ac4a
\ No newline at end of file
+5561bf72dd5d675c7a3e953233cc98bb688bf5ec
\ No newline at end of file
diff --git a/third_party/firefox_jsshell/win/jsshell.tar.gz.sha1 b/third_party/firefox_jsshell/win/jsshell.tar.gz.sha1
index f8c7c1b..c6f0f848 100644
--- a/third_party/firefox_jsshell/win/jsshell.tar.gz.sha1
+++ b/third_party/firefox_jsshell/win/jsshell.tar.gz.sha1
@@ -1 +1 @@
-354b952f339d454fb89f2a8288f755d37eae6443
\ No newline at end of file
+c0f0c3347a1eb9ebc6a920d2d5c2f9c2b8371d0a
\ No newline at end of file
diff --git a/tools/VERSION b/tools/VERSION
index 392d057..27a6c02 100644
--- a/tools/VERSION
+++ b/tools/VERSION
@@ -26,7 +26,7 @@
 #
 CHANNEL dev
 MAJOR 1
-MINOR 21
+MINOR 22
 PATCH 0
-PRERELEASE 11
-PRERELEASE_PATCH 3
+PRERELEASE 0
+PRERELEASE_PATCH 0
diff --git a/tools/create_pkg_manifest.py b/tools/create_pkg_manifest.py
new file mode 100755
index 0000000..932f263
--- /dev/null
+++ b/tools/create_pkg_manifest.py
@@ -0,0 +1,108 @@
+#!/usr/bin/env python
+# Copyright 2016 The Dart project authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# Usage: create_pkg_manifest.py --deps <DEPS file> --output <jiri manifest>
+#
+# This script parses the DEPS file, extracts dependencies that live under
+# third_party/pkg, and writes them to a file suitable for consumption as a
+# jiri manifest for Fuchsia. It is assumed that the Dart tree is under
+# //dart in the Fuchsia world, and so the dependencies extracted by this script
+# will go under //dart/third_party/pkg.
+
+import argparse
+import os
+import sys
+import utils
+
+SCRIPT_DIR = os.path.dirname(sys.argv[0])
+DART_ROOT = os.path.realpath(os.path.join(SCRIPT_DIR, '..'))
+
+# Used in parsing the DEPS file.
+class VarImpl(object):
+  def __init__(self, local_scope):
+    self._local_scope = local_scope
+
+  def Lookup(self, var_name):
+    """Implements the Var syntax."""
+    if var_name in self._local_scope.get("vars", {}):
+      return self._local_scope["vars"][var_name]
+    raise Exception("Var is not defined: %s" % var_name)
+
+
+def ParseDepsFile(deps_file):
+  local_scope = {}
+  var = VarImpl(local_scope)
+  global_scope = {
+    'Var': var.Lookup,
+    'deps_os': {},
+  }
+  # Read the content.
+  with open(deps_file, 'r') as fp:
+    deps_content = fp.read()
+
+  # Eval the content.
+  exec(deps_content, global_scope, local_scope)
+
+  # Extract the deps and filter.
+  deps = local_scope.get('deps', {})
+  filtered_deps = {}
+  for k, v in deps.iteritems():
+    if 'sdk/third_party/pkg' in k:
+      new_key = k.replace('sdk', 'dart', 1)
+      filtered_deps[new_key] = v
+
+  return filtered_deps
+
+
+def WriteManifest(deps, manifest_file):
+  project_template = """
+    <project name="%s"
+             path="%s"
+             remote="%s"
+             revision="%s"/>
+"""
+  warning = ('<!-- This file is generated by '
+             '//dart/tools/create_pkg_manifest.py. DO NOT EDIT -->\n')
+  with open(manifest_file, 'w') as manifest:
+    manifest.write(warning)
+    manifest.write('<?xml version="1.0" encoding="UTF-8"?>\n')
+    manifest.write('<manifest>\n')
+    manifest.write('  <projects>\n')
+    for path, remote in deps.iteritems():
+      remote_components = remote.split('@')
+      remote_url = remote_components[0]
+      remote_version = remote_components[1]
+      manifest.write(
+          project_template % (path, path, remote_url, remote_version))
+    manifest.write('  </projects>\n')
+    manifest.write('</manifest>\n')
+
+
+def ParseArgs(args):
+  args = args[1:]
+  parser = argparse.ArgumentParser(
+      description='A script to generate a jiri manifest for third_party/pkg.')
+
+  parser.add_argument('--deps', '-d',
+      type=str,
+      help='Input DEPS file.',
+      default=os.path.join(DART_ROOT, 'DEPS'))
+  parser.add_argument('--output', '-o',
+      type=str,
+      help='Output jiri manifest.',
+      default=os.path.join(DART_ROOT, 'dart_third_party_pkg.manifest'))
+
+  return parser.parse_args(args)
+
+
+def Main(argv):
+  args = ParseArgs(argv)
+  deps = ParseDepsFile(args.deps)
+  WriteManifest(deps, args.output)
+  return 0
+
+
+if __name__ == '__main__':
+  sys.exit(Main(sys.argv))
diff --git a/tools/download_prebuilt_sdk.py b/tools/download_prebuilt_sdk.py
new file mode 100755
index 0000000..f3c4385
--- /dev/null
+++ b/tools/download_prebuilt_sdk.py
@@ -0,0 +1,52 @@
+#!/usr/bin/env python
+# Copyright 2016 The Dart project 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 os
+import subprocess
+import sys
+import tarfile
+import urllib
+import utils
+
+HOST_OS = utils.GuessOS()
+HOST_ARCH = utils.GuessArchitecture()
+SCRIPT_DIR = os.path.dirname(sys.argv[0])
+DART_ROOT = os.path.realpath(os.path.join(SCRIPT_DIR, '..'))
+
+BUCKET_NAME = 'dart-dependencies'
+
+def host_os_for_sdk(host_os):
+  if host_os.startswith('macos'):
+    return 'mac'
+  if host_os.startswith('win'):
+    return 'win'
+  return host_os
+
+def main(argv):
+  host_os = host_os_for_sdk(HOST_OS)
+  sdk_path = os.path.join(DART_ROOT, 'tools', 'sdks', host_os)
+  stamp_path = os.path.join(sdk_path, 'dart-sdk.tar.gz.stamp')
+  sha_path = os.path.join(sdk_path, 'dart-sdk.tar.gz.sha1')
+  tgz_path = os.path.join(sdk_path, 'dart-sdk.tar.gz')
+
+  stamp = ''
+  if os.path.isfile(stamp_path):
+    with open(stamp_path, 'r') as fp:
+      stamp = fp.read()
+
+  with open(sha_path, 'r') as fp:
+    sha = fp.read()
+
+  if stamp != sha:
+    url = ('https://%s.storage.googleapis.com/%s' % (BUCKET_NAME, sha))
+    print 'Downloading prebuilt Dart SDK from: ' + url
+    urllib.urlretrieve(url, tgz_path)
+    with tarfile.open(tgz_path) as tar:
+      tar.extractall(sdk_path)
+    with open(stamp_path, 'w') as fp:
+      fp.write(sha)
+
+if __name__ == '__main__':
+  sys.exit(main(sys.argv))
diff --git a/tools/observatory_tool.py b/tools/observatory_tool.py
index f54c93d..08f8073 100755
--- a/tools/observatory_tool.py
+++ b/tools/observatory_tool.py
@@ -188,7 +188,7 @@
                       options.pub_executable,
                       options.pub_snapshot,
                       ['build',
-                       '-DOBS_VER=' + utils.GetVersion(),
+                       '-DOBS_VER=' + utils.GetVersion(ignore_svn_revision=True),
                        '--output', args[0]],
                       options.silent)
   elif (cmd == 'deploy'):
diff --git a/tools/testing/dart/compiler_configuration.dart b/tools/testing/dart/compiler_configuration.dart
index 0a15772..b777fb7 100644
--- a/tools/testing/dart/compiler_configuration.dart
+++ b/tools/testing/dart/compiler_configuration.dart
@@ -79,10 +79,9 @@
             useFastStartup: useFastStartup,
             extraDart2jsOptions:
                 TestUtils.getExtraOptions(configuration, 'dart2js_options'));
-      case 'dart2appjit':
-      case 'dart2app':
+      case 'app_jit':
         return new Dart2AppSnapshotCompilerConfiguration(
-            isDebug: isDebug, isChecked: isChecked, useBlobs: useBlobs);
+            isDebug: isDebug, isChecked: isChecked);
       case 'precompiler':
         return new PrecompilerCompilerConfiguration(
             isDebug: isDebug,
@@ -94,7 +93,8 @@
         return ComposedCompilerConfiguration.createDartKConfiguration(
             isHostChecked: isHostChecked,
             useSdk: useSdk,
-            verify: verifyKernel);
+            verify: verifyKernel,
+            strong: isStrong);
       case 'dartkp':
         return ComposedCompilerConfiguration.createDartKPConfiguration(
             isHostChecked: isHostChecked,
@@ -102,7 +102,8 @@
             useBlobs: useBlobs,
             isAndroid: configuration['system'] == 'android',
             useSdk: useSdk,
-            verify: verifyKernel);
+            verify: verifyKernel,
+            strong: isStrong);
       case 'none':
         return new NoneCompilerConfiguration(
             isDebug: isDebug,
@@ -215,9 +216,10 @@
 
 /// The "dartk" compiler.
 class DartKCompilerConfiguration extends CompilerConfiguration {
-  final bool verify;
+  final bool verify, strong;
 
-  DartKCompilerConfiguration({bool isHostChecked, bool useSdk, this.verify})
+  DartKCompilerConfiguration({bool isHostChecked, bool useSdk, this.verify,
+        this.strong})
       : super._subclass(isHostChecked: isHostChecked, useSdk: useSdk);
 
   @override
@@ -236,6 +238,7 @@
       '$buildDir/patched_sdk',
       '--link',
       '--target=vm',
+      strong ? '--strong' : null,
       verify ? '--verify-ir' : null,
       '--out',
       outputFileName
@@ -367,13 +370,13 @@
 
   static ComposedCompilerConfiguration createDartKPConfiguration(
       {bool isHostChecked, String arch, bool useBlobs, bool isAndroid,
-       bool useSdk, bool verify}) {
+       bool useSdk, bool verify, bool strong}) {
     var nested = [];
 
     // Compile with dartk.
     nested.add(new PipelineCommand.runWithGlobalArguments(
         new DartKCompilerConfiguration(isHostChecked: isHostChecked,
-            useSdk: useSdk, verify: verify)));
+            useSdk: useSdk, verify: verify, strong: strong)));
 
     // Run the normal precompiler.
     nested.add(new PipelineCommand.runWithPreviousKernelOutput(
@@ -384,13 +387,13 @@
   }
 
   static ComposedCompilerConfiguration createDartKConfiguration(
-      {bool isHostChecked, bool useSdk, bool verify}) {
+      {bool isHostChecked, bool useSdk, bool verify, bool strong}) {
     var nested = [];
 
     // Compile with dartk.
     nested.add(new PipelineCommand.runWithGlobalArguments(
         new DartKCompilerConfiguration(isHostChecked: isHostChecked,
-            useSdk: useSdk, verify: verify)));
+            useSdk: useSdk, verify: verify, strong: strong)));
 
     return new ComposedCompilerConfiguration(nested, isPrecompiler: false);
   }
@@ -697,9 +700,8 @@
 }
 
 class Dart2AppSnapshotCompilerConfiguration extends CompilerConfiguration {
-  final bool useBlobs;
-  Dart2AppSnapshotCompilerConfiguration({bool isDebug, bool isChecked, bool useBlobs})
-      : super._subclass(isDebug: isDebug, isChecked: isChecked), this.useBlobs = useBlobs;
+  Dart2AppSnapshotCompilerConfiguration({bool isDebug, bool isChecked})
+      : super._subclass(isDebug: isDebug, isChecked: isChecked);
 
   int computeTimeoutMultiplier() {
     int multiplier = 2;
@@ -714,10 +716,11 @@
       CommandBuilder commandBuilder,
       List arguments,
       Map<String, String> environmentOverrides) {
+    var snapshot = "$tempDir/out.jitsnapshot";
     return new CommandArtifact(<Command>[
       this.computeCompilationCommand(tempDir, buildDir,
           CommandBuilder.instance, arguments, environmentOverrides)
-    ], tempDir, 'application/dart-snapshot');
+    ], snapshot, 'application/dart-snapshot');
   }
 
   CompilationCommand computeCompilationCommand(
@@ -728,15 +731,13 @@
       Map<String, String> environmentOverrides) {
     var exec = "$buildDir/dart";
     var args = new List();
-    args.add("--snapshot=$tempDir/out.jitsnapshot");
+    var snapshot = "$tempDir/out.jitsnapshot";
+    args.add("--snapshot=$snapshot");
     args.add("--snapshot-kind=app-jit");
-    if (useBlobs) {
-      args.add("--use-blobs");
-    }
     args.addAll(arguments);
 
     return commandBuilder.getCompilationCommand(
-        'dart2snapshot',
+        'app_jit',
         tempDir,
         !useSdk,
         bootstrapDependencies(buildDir),
@@ -771,10 +772,16 @@
       args.add('--enable_asserts');
       args.add('--enable_type_checks');
     }
-    return args
+    args
       ..addAll(vmOptions)
       ..addAll(sharedOptions)
       ..addAll(originalArguments);
+    for (var i = 0; i < args.length; i++) {
+      if (args[i].endsWith(".dart")) {
+        args[i] = artifact.filename;
+      }
+    }
+    return args;
   }
 }
 
diff --git a/tools/testing/dart/runtime_configuration.dart b/tools/testing/dart/runtime_configuration.dart
index 97c918a..33b83e9 100644
--- a/tools/testing/dart/runtime_configuration.dart
+++ b/tools/testing/dart/runtime_configuration.dart
@@ -4,8 +4,6 @@
 
 library runtime_configuration;
 
-import 'dart:io' show Platform;
-
 import 'compiler_configuration.dart' show CommandArtifact;
 
 // TODO(ahe): Remove this import, we can precompute all the values required
@@ -52,9 +50,6 @@
       case 'vm':
         return new StandaloneDartRuntimeConfiguration();
 
-      case 'dart_app':
-        return new DartAppRuntimeConfiguration(useBlobs: useBlobs);
-
       case 'dart_precompiled':
         if (configuration['system'] == 'android') {
           return new DartPrecompiledAdbRuntimeConfiguration(useBlobs: useBlobs);
@@ -218,7 +213,9 @@
       Map<String, String> environmentOverrides) {
     String script = artifact.filename;
     String type = artifact.mimeType;
-    if (script != null && type != 'application/dart') {
+    if (script != null &&
+        type != 'application/dart' &&
+        type != 'application/dart-snapshot') {
       throw "Dart VM cannot run files of type '$type'.";
     }
     String executable = suite.configuration['noopt']
@@ -230,37 +227,6 @@
   }
 }
 
-class DartAppRuntimeConfiguration extends DartVmRuntimeConfiguration {
-  final bool useBlobs;
-  DartAppRuntimeConfiguration({bool useBlobs}) : useBlobs = useBlobs;
-
-  List<Command> computeRuntimeCommands(
-      TestSuite suite,
-      CommandBuilder commandBuilder,
-      CommandArtifact artifact,
-      List<String> arguments,
-      Map<String, String> environmentOverrides) {
-    String script = artifact.filename;
-    String type = artifact.mimeType;
-    if (script != null && type != 'application/dart-snapshot') {
-      throw "dart_app cannot run files of type '$type'.";
-    }
-
-    var args = new List();
-    args.addAll(arguments);
-    for (var i = 0; i < args.length; i++) {
-      if (args[i].endsWith(".dart")) {
-        args[i] = "${artifact.filename}/out.jitsnapshot";
-      }
-    }
-
-    return <Command>[
-      commandBuilder.getVmCommand(suite.dartVmBinaryFileName,
-          args, environmentOverrides)
-    ];
-  }
-}
-
 class DartPrecompiledRuntimeConfiguration extends DartVmRuntimeConfiguration {
   final bool useBlobs;
   DartPrecompiledRuntimeConfiguration({bool useBlobs}) : useBlobs = useBlobs;
diff --git a/tools/testing/dart/status_file_parser.dart b/tools/testing/dart/status_file_parser.dart
index c4be801..a26c792 100644
--- a/tools/testing/dart/status_file_parser.dart
+++ b/tools/testing/dart/status_file_parser.dart
@@ -28,6 +28,19 @@
   static Expectation MISSING_STATIC_WARNING = byName('MissingStaticWarning');
   static Expectation PUB_GET_ERROR = byName('PubGetError');
 
+  // Special 'CRASH' cases
+  static Expectation DARTK_CRASH = byName('DartkCrash');
+
+  // Special 'TIMEOUT' cases
+  static Expectation DARTK_TIMEOUT = byName('DartkTimeout');
+
+  // Special 'MISSING_COMPILETIME_ERROR'
+  static Expectation DARTK_MISSING_COMPILETIME_ERROR =
+      byName('DartkMissingCompileTimeError');
+
+  // Special 'COMPILETIME_ERROR'
+  static Expectation DARTK_COMPILETIME_ERROR = byName('DartkCompileTimeError');
+
   // "meta expectations"
   static Expectation OK = byName('Ok');
   static Expectation SLOW = byName('Slow');
@@ -63,15 +76,21 @@
       }
 
       var fail = build("Fail");
+      var crash = build("Crash");
+      var timeout = build("Timeout");
       build("Pass");
-      build("Crash");
-      build("Timeout");
 
-      build("MissingCompileTimeError", group: fail);
+      var missingCompileError = build("MissingCompileTimeError", group: fail);
+      var compileError = build("CompileTimeError", group: fail);
       build("MissingRuntimeError", group: fail);
-      build("CompileTimeError", group: fail);
       build("RuntimeError", group: fail);
 
+      // Dartk sub expectations
+      build("DartkCrash", group: crash);
+      build("DartkTimeout", group: timeout);
+      build("DartkMissingCompileTimeError", group: missingCompileError);
+      build("DartkCompileTimeError", group: compileError);
+
       build("MissingStaticWarning", group: fail);
       build("StaticWarning", group: fail);
 
diff --git a/tools/testing/dart/test_options.dart b/tools/testing/dart/test_options.dart
index 83856fe..f84a560 100644
--- a/tools/testing/dart/test_options.dart
+++ b/tools/testing/dart/test_options.dart
@@ -88,8 +88,9 @@
             'precompiler',
             'dart2js',
             'dart2analyzer',
-            'dart2app',
-            'dart2appjit',
+            'app_jit',
+            'dart2app',  // TODO(rmacnak): Remove after updating bots.
+            'dart2appjit',  // TODO(rmacnak): Remove after updating bots.
             'dartk',
             'dartkp'
           ],
@@ -103,8 +104,6 @@
     dart_precompiled: Run a precompiled snapshot on a variant of the standalone
                       dart vm lacking a JIT.
 
-    dart_app: Run a full app snapshot, with or without cached unoptimized code.
-
     d8: Run JavaScript from the command line using v8.
 
     jsshell: Run JavaScript from the command line using firefox js-shell.
@@ -128,7 +127,7 @@
           [
             'vm',
             'dart_precompiled',
-            'dart_app',
+            'dart_app',  // TODO(rmacnak): Remove after updating bots.
             'd8',
             'jsshell',
             'drt',
@@ -696,16 +695,11 @@
       case 'dart2analyzer':
         validRuntimes = const ['none'];
         break;
-      case 'dart2app':
-      case 'dart2appjit':
-        validRuntimes = const ['dart_app'];
-        break;
-      case 'precompiler':
-        validRuntimes = const ['dart_precompiled'];
-        break;
+      case 'app_jit':
       case 'dartk':
         validRuntimes = const ['vm'];
         break;
+      case 'precompiler':
       case 'dartkp':
         validRuntimes = const ['dart_precompiled'];
         break;
@@ -750,6 +744,15 @@
    * into a list of configurations with exactly one value per key.
    */
   List<Map> _expandConfigurations(Map configuration) {
+    // TODO(rmacnak): Remove after updating bots.
+    if (configuration['runtime'] == 'dart_app') {
+      configuration['runtime'] = 'vm';
+    }
+    if (configuration['compiler'] == 'dart2app' ||
+        configuration['compiler'] == 'dart2appjit') {
+      configuration['compiler'] = 'app_jit';
+    }
+
     // Expand the pseudo-values such as 'all'.
     if (configuration['arch'] == 'all') {
       configuration['arch'] = 'ia32,x64,simarm,simarm64,simmips,simdbc64';
diff --git a/tools/testing/dart/test_runner.dart b/tools/testing/dart/test_runner.dart
index 1cb1a39..bc6be64 100644
--- a/tools/testing/dart/test_runner.dart
+++ b/tools/testing/dart/test_runner.dart
@@ -1664,6 +1664,20 @@
     return !hasCrashed && !timedOut && exitCode == 0;
   }
 
+  Expectation result(TestCase testCase) {
+    Expectation result = super.result(testCase);
+    if (result.canBeOutcomeOf(Expectation.CRASH)) {
+      return Expectation.DARTK_CRASH;
+    } else if (result.canBeOutcomeOf(Expectation.TIMEOUT)) {
+      return Expectation.DARTK_TIMEOUT;
+    } else if (result.canBeOutcomeOf(Expectation.MISSING_COMPILETIME_ERROR)) {
+      return Expectation.DARTK_MISSING_COMPILETIME_ERROR;
+    } else if (result.canBeOutcomeOf(Expectation.COMPILETIME_ERROR)) {
+      return Expectation.DARTK_COMPILETIME_ERROR;
+    }
+    return result;
+  }
+
   // If the compiler was able to produce a Kernel IR file we want to run the
   // result on the Dart VM.  We therefore mark the [KernelCompilationCommand] as
   // successful.
@@ -1754,7 +1768,7 @@
         command, exitCode, timedOut, stdout, stderr, time, pid);
   } else if (command is CompilationCommand) {
     if (command.displayName == 'precompiler' ||
-        command.displayName == 'dart2snapshot') {
+        command.displayName == 'app_jit') {
       return new VmCommandOutputImpl(
           command, exitCode, timedOut, stdout, stderr, time, pid);
     }
diff --git a/tools/testing/dart/test_suite.dart b/tools/testing/dart/test_suite.dart
index c13b69a..4fed64f 100644
--- a/tools/testing/dart/test_suite.dart
+++ b/tools/testing/dart/test_suite.dart
@@ -1831,11 +1831,10 @@
   }
 
   List<List<String>> getVmOptions(Map optionsFromFile) {
-    var COMPILERS = const ['none', 'precompiler', 'dart2app', 'dart2appjit'];
+    var COMPILERS = const ['none', 'precompiler', 'app_jit'];
     var RUNTIMES = const [
       'none',
       'dart_precompiled',
-      'dart_app',
       'vm',
       'drt',
       'dartium',
diff --git a/tools/utils.py b/tools/utils.py
index 51a3a03..341321d 100644
--- a/tools/utils.py
+++ b/tools/utils.py
@@ -316,8 +316,8 @@
 
   return '%s.%s.%s%s' % (version.major, version.minor, version.patch, postfix)
 
-def GetVersion():
-  return GetSemanticSDKVersion()
+def GetVersion(ignore_svn_revision=False):
+  return GetSemanticSDKVersion(ignore_svn_revision)
 
 # The editor used to produce the VERSION file put on gcs. We now produce this
 # in the bots archiving the sdk.