| OLD | NEW |
| 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 Loading... |
| 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 Loading... |
| 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 } |
| OLD | NEW |