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

Unified Diff: sdk/lib/_internal/compiler/implementation/js_backend/backend.dart

Issue 201613006: Introduces the new syntax for deferred loading (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 9 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: sdk/lib/_internal/compiler/implementation/js_backend/backend.dart
diff --git a/sdk/lib/_internal/compiler/implementation/js_backend/backend.dart b/sdk/lib/_internal/compiler/implementation/js_backend/backend.dart
index d157b569549862ab23235d589406930f0d2b206e..45d4f972fa5fa9394a1ec156bb0cecb09c62deeb 100644
--- a/sdk/lib/_internal/compiler/implementation/js_backend/backend.dart
+++ b/sdk/lib/_internal/compiler/implementation/js_backend/backend.dart
@@ -1556,6 +1556,14 @@ class JavaScriptBackend extends Backend {
mustRetainMetadata = true;
} else if (element == getIsolateAffinityTagMarker) {
needToInitializeIsolateAffinityTag = true;
+ } else if (element.isDeferredLoaderGetter()) {
+ // TODO(sigurdm): Create a function registerLoadLibraryAccess.
+ if (compiler.loadLibraryFunction == null) {
+ compiler.loadLibraryFunction =
+ compiler.findHelper("_loadLibraryWrapper");
+ enqueueInResolution(compiler.loadLibraryFunction,
+ compiler.globalDependencies);
+ }
}
customElementsAnalysis.registerStaticUse(element, enqueuer);
}

Powered by Google App Engine
This is Rietveld 408576698