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

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

Issue 12254010: Make Uri.isAbsolute and Uri.hasAuthority getters. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
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
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/apiimpl.dart ('k') | sdk/lib/uri/uri.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 if (patchUri != null) { 351 if (patchUri != null) {
352 compiler.patchParser.patchLibrary(handler, patchUri, library); 352 compiler.patchParser.patchLibrary(handler, patchUri, library);
353 } 353 }
354 } 354 }
355 355
356 /** 356 /**
357 * Handle a part tag in the scope of [library]. The [resolvedUri] given is 357 * Handle a part tag in the scope of [library]. The [resolvedUri] given is
358 * used as is, any URI resolution should be done beforehand. 358 * used as is, any URI resolution should be done beforehand.
359 */ 359 */
360 void scanPart(Part part, Uri resolvedUri, LibraryElement library) { 360 void scanPart(Part part, Uri resolvedUri, LibraryElement library) {
361 if (!resolvedUri.isAbsolute()) throw new ArgumentError(resolvedUri); 361 if (!resolvedUri.isAbsolute) throw new ArgumentError(resolvedUri);
362 Uri readableUri = compiler.translateResolvedUri(library, resolvedUri, part); 362 Uri readableUri = compiler.translateResolvedUri(library, resolvedUri, part);
363 Script sourceScript = compiler.readScript(readableUri, part); 363 Script sourceScript = compiler.readScript(readableUri, part);
364 CompilationUnitElement unit = 364 CompilationUnitElement unit =
365 new CompilationUnitElementX(sourceScript, library); 365 new CompilationUnitElementX(sourceScript, library);
366 compiler.withCurrentElement(unit, () { 366 compiler.withCurrentElement(unit, () {
367 compiler.scanner.scan(unit); 367 compiler.scanner.scan(unit);
368 if (unit.partTag == null) { 368 if (unit.partTag == null) {
369 bool wasDiagnosticEmitted = false; 369 bool wasDiagnosticEmitted = false;
370 compiler.withCurrentElement(library, () { 370 compiler.withCurrentElement(library, () {
371 wasDiagnosticEmitted = 371 wasDiagnosticEmitted =
(...skipping 456 matching lines...) Expand 10 before | Expand all | Expand 10 after
828 } 828 }
829 829
830 /** 830 /**
831 * Registers all top-level entities of [library] as starting point for the 831 * Registers all top-level entities of [library] as starting point for the
832 * fixed-point computation of the import/export scopes. 832 * fixed-point computation of the import/export scopes.
833 */ 833 */
834 void registerLibraryExports(LibraryElement library) { 834 void registerLibraryExports(LibraryElement library) {
835 nodeMap[library].registerInitialExports(); 835 nodeMap[library].registerInitialExports();
836 } 836 }
837 } 837 }
OLDNEW
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/apiimpl.dart ('k') | sdk/lib/uri/uri.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698