Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(679)

Unified Diff: pkg/compiler/lib/src/compiler.dart

Issue 839323003: Implementation of async-await transformation on js ast. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Implement new ssa-nodes in ssa-tracer. Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/compiler.dart
diff --git a/pkg/compiler/lib/src/compiler.dart b/pkg/compiler/lib/src/compiler.dart
index 9b3f9c920c7a69395e76e62a669473d6b70a014f..cffa2e0025c61be0cf4b07677a658e9b24207261 100644
--- a/pkg/compiler/lib/src/compiler.dart
+++ b/pkg/compiler/lib/src/compiler.dart
@@ -176,6 +176,11 @@ class CodegenRegistry extends Registry {
void registerInstantiation(InterfaceType type) {
world.registerInstantiatedType(type, this);
}
+
+ void registerAsyncMarker(FunctionElement element) {
+ backend.registerAsyncMarker(element, world, this);
+ }
+
}
/// [WorkItem] used exclusively by the [CodegenEnqueuer].
@@ -229,6 +234,8 @@ abstract class Registry {
void registerInstantiation(InterfaceType type);
void registerGetOfStaticFunction(FunctionElement element);
+
+ void registerAsyncMarker(FunctionElement element);
}
abstract class Backend {
@@ -516,6 +523,10 @@ abstract class Backend {
void forgetElement(Element element) {}
void registerMainHasArguments(Enqueuer enqueuer) {}
+
+ void registerAsyncMarker(FunctionElement element,
+ Enqueuer enqueuer,
+ Registry registry) {}
}
/// Backend callbacks function specific to the resolution phase.
@@ -740,9 +751,6 @@ abstract class Compiler implements DiagnosticListener {
final bool suppressWarnings;
- /// `true` if async/await features are supported.
- final bool enableAsyncAwait;
-
/// If `true`, some values are cached for reuse in incremental compilation.
/// Incremental compilation is basically calling [run] more than once.
final bool hasIncrementalSupport;
@@ -1004,7 +1012,6 @@ abstract class Compiler implements DiagnosticListener {
this.suppressWarnings: false,
bool hasIncrementalSupport: false,
this.enableExperimentalMirrors: false,
- this.enableAsyncAwait: false,
this.allowNativeExtensions: false,
this.generateCodeWithCompileTimeErrors: false,
api.CompilerOutputProvider outputProvider,

Powered by Google App Engine
This is Rietveld 408576698