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

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

Issue 2875313002: Access BackendUsage through ClosedWorld (Closed)
Patch Set: Created 3 years, 7 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
« no previous file with comments | « pkg/compiler/lib/src/compiler.dart ('k') | pkg/compiler/lib/src/dump_info.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/deferred_load.dart
diff --git a/pkg/compiler/lib/src/deferred_load.dart b/pkg/compiler/lib/src/deferred_load.dart
index c9925d4e849eb57a1530397512d4868f5e80cf5a..baeb2aa1a46cc89a5f8df54478a8f4efe1c5bad9 100644
--- a/pkg/compiler/lib/src/deferred_load.dart
+++ b/pkg/compiler/lib/src/deferred_load.dart
@@ -34,7 +34,6 @@ import 'elements/elements.dart'
TypedefElement;
import 'elements/entities.dart';
import 'js_backend/js_backend.dart' show JavaScriptBackend;
-import 'js_backend/backend_usage.dart' show BackendUsage;
import 'resolution/resolution.dart' show AnalyzableElementX;
import 'resolution/tree_elements.dart' show TreeElements;
import 'tree/tree.dart' as ast;
@@ -44,6 +43,7 @@ import 'universe/world_impact.dart'
import 'util/setlet.dart' show Setlet;
import 'util/uri_extras.dart' as uri_extras;
import 'util/util.dart' show makeUnique;
+import 'world.dart' show ClosedWorld;
/// A "hunk" of the program that will be loaded whenever one of its [imports]
/// are loaded.
@@ -162,7 +162,6 @@ class DeferredLoadTask extends CompilerTask {
JavaScriptBackend get backend => compiler.backend;
DiagnosticReporter get reporter => compiler.reporter;
- BackendUsage get _backendUsage => backend.backendUsage;
/// Returns the [OutputUnit] where [element] belongs.
OutputUnit outputUnitForElement(Element element) {
@@ -676,7 +675,7 @@ class DeferredLoadTask extends CompilerTask {
}
}
- void onResolutionComplete(FunctionEntity main) {
+ void onResolutionComplete(FunctionEntity main, ClosedWorld closedWorld) {
if (!isProgramSplit) {
allOutputUnits.add(mainOutputUnit);
return;
@@ -700,12 +699,12 @@ class DeferredLoadTask extends CompilerTask {
// particular element, for example, startRootIsolate. This set
// also contains elements for which we lack precise information.
for (MethodElement element
- in _backendUsage.globalFunctionDependencies) {
+ in closedWorld.backendUsage.globalFunctionDependencies) {
_mapDependencies(
element: element.implementation, import: _fakeMainImport);
}
for (ClassElement element
- in _backendUsage.globalClassDependencies) {
+ in closedWorld.backendUsage.globalClassDependencies) {
_mapDependencies(
element: element.implementation, import: _fakeMainImport);
}
« no previous file with comments | « pkg/compiler/lib/src/compiler.dart ('k') | pkg/compiler/lib/src/dump_info.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698