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

Side by Side Diff: dart/sdk/lib/_internal/compiler/implementation/library_loader.dart

Issue 12033003: Deferred (aka lazy) loading of static functions. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of dart2js; 5 part of dart2js;
6 6
7 /** 7 /**
8 * [CompilerTask] for loading libraries and setting up the import/export scopes. 8 * [CompilerTask] for loading libraries and setting up the import/export scopes.
9 * 9 *
10 * The library loader uses four different kinds of URIs in different parts of 10 * The library loader uses four different kinds of URIs in different parts of
(...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after
789 node.registerImports(compiler); 789 node.registerImports(compiler);
790 }); 790 });
791 } 791 }
792 792
793 /** 793 /**
794 * Registers that [library] depends on [loadedLibrary] through [tag]. 794 * Registers that [library] depends on [loadedLibrary] through [tag].
795 */ 795 */
796 void registerDependency(LibraryElement library, 796 void registerDependency(LibraryElement library,
797 LibraryDependency tag, 797 LibraryDependency tag,
798 LibraryElement loadedLibrary) { 798 LibraryElement loadedLibrary) {
799 if (tag != null) {
800 library.resolvedTag(tag, loadedLibrary);
801 }
799 if (tag is Export) { 802 if (tag is Export) {
800 // [loadedLibrary] is exported by [library]. 803 // [loadedLibrary] is exported by [library].
801 LibraryDependencyNode exportingNode = nodeMap[library]; 804 LibraryDependencyNode exportingNode = nodeMap[library];
802 if (loadedLibrary.exportsHandled) { 805 if (loadedLibrary.exportsHandled) {
803 // Export scope already computed on [loadedLibrary]. 806 // Export scope already computed on [loadedLibrary].
804 var combinatorFilter = new CombinatorFilter.fromTag(tag); 807 var combinatorFilter = new CombinatorFilter.fromTag(tag);
805 exportingNode.registerHandledExports(loadedLibrary, combinatorFilter); 808 exportingNode.registerHandledExports(loadedLibrary, combinatorFilter);
806 return; 809 return;
807 } 810 }
808 LibraryDependencyNode exportedNode = nodeMap[loadedLibrary]; 811 LibraryDependencyNode exportedNode = nodeMap[loadedLibrary];
(...skipping 19 matching lines...) Expand all
828 } 831 }
829 832
830 /** 833 /**
831 * Registers all top-level entities of [library] as starting point for the 834 * Registers all top-level entities of [library] as starting point for the
832 * fixed-point computation of the import/export scopes. 835 * fixed-point computation of the import/export scopes.
833 */ 836 */
834 void registerLibraryExports(LibraryElement library) { 837 void registerLibraryExports(LibraryElement library) {
835 nodeMap[library].registerInitialExports(); 838 nodeMap[library].registerInitialExports();
836 } 839 }
837 } 840 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698