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

Unified Diff: lib/compiler/implementation/compiler.dart

Issue 10990060: Added support for exports and re-exports. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Removed redundant check. Created 8 years, 3 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: lib/compiler/implementation/compiler.dart
diff --git a/lib/compiler/implementation/compiler.dart b/lib/compiler/implementation/compiler.dart
index c316b5c551d46de15b61ba2de4ac126b1ea1f123..5aa454b39a26cf8c807110c9b146a4ee535428b4 100644
--- a/lib/compiler/implementation/compiler.dart
+++ b/lib/compiler/implementation/compiler.dart
@@ -383,22 +383,24 @@ class Compiler implements DiagnosticListener {
initializeSpecialClasses();
}
- void importCoreLibrary(LibraryElement library) {
+ /**
+ * Lazily loads and returns the [LibraryElement] for the dart:core library.
+ */
+ LibraryElement importCoreLibrary(ImportExportHandler handler) {
Uri coreUri = new Uri.fromComponents(scheme: 'dart', path: 'core');
if (coreLibrary === null) {
- coreLibrary = scanner.loadLibrary(coreUri, null, coreUri);
+ coreLibrary =
+ scanner.loadLibraryInternal(handler, coreUri, null, coreUri);
}
- scanner.importLibrary(library,
- coreLibrary,
- null,
- library.entryCompilationUnit);
+ return coreLibrary;
}
- void patchDartLibrary(LibraryElement library, String dartLibraryPath) {
+ void patchDartLibrary(ImportExportHandler handler,
+ LibraryElement library, String dartLibraryPath) {
if (library.isPatched) return;
Uri patchUri = resolvePatchUri(dartLibraryPath);
if (patchUri !== null) {
- patchParser.patchLibrary(patchUri, library);
+ patchParser.patchLibrary(handler, patchUri, library);
}
}
« no previous file with comments | « no previous file | lib/compiler/implementation/elements/elements.dart » ('j') | lib/compiler/implementation/elements/elements.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698