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

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

Issue 10894005: Remove library_map.dart. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Merge to tip of tree. Created 8 years, 4 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 | « lib/compiler/implementation/apiimpl.dart ('k') | pkg/dartdoc/dartdoc.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/library_map.dart
diff --git a/lib/compiler/implementation/library_map.dart b/lib/compiler/implementation/library_map.dart
deleted file mode 100644
index 6fc5f6a17b0ffae55fba787a3205c3ee30332842..0000000000000000000000000000000000000000
--- a/lib/compiler/implementation/library_map.dart
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-// TODO(ahe): Long term, it would probably be better if we do not use
-// executable code to define the locations of libraries.
-
-#library('library_map');
-#import('../../../lib/_internal/libraries.dart', prefix: "libs");
-
-/**
- * Simple structure providing the path to a library and an optional path
- * to a patch file for the library.
- */
-class LibraryInfo {
- final libs.LibraryInfo info;
- const LibraryInfo(this.info);
-
- String get libraryPath() {
- String libPath = info.dart2jsPath;
- if (libPath === null) libPath = info.path;
- return "lib/$libPath";
- }
-
- String get patchPath() {
- if (info.dart2jsPatchPath === null) return null;
- return "lib/${info.dart2jsPatchPath}";
- }
-
- bool get isInternal => info.category === "Internal";
-}
-
-class Dart2JSLibraryMap {
- const Dart2JSLibraryMap();
-
- LibraryInfo operator[](String dartName) {
- libs.LibraryInfo info = libs.LIBRARIES[dartName];
- if (info === null) return null;
- if (!info.isDart2JsLibrary()) {
- // Dart2js can't handle internal libraries for other backends.
- return null;
- }
- return new LibraryInfo(info);
- }
-}
-
-final Dart2JSLibraryMap DART2JS_LIBRARY_MAP = const Dart2JSLibraryMap();
« no previous file with comments | « lib/compiler/implementation/apiimpl.dart ('k') | pkg/dartdoc/dartdoc.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698