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

Side by Side Diff: pkg/front_end/lib/src/fasta/loader.dart

Issue 2953703002: Tweak public APIs and use them in patch_sdk, dart2js, and kernel-service (Closed)
Patch Set: Created 3 years, 5 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 library fasta.loader; 5 library fasta.loader;
6 6
7 import 'dart:async' show Future; 7 import 'dart:async' show Future;
8 8
9 import 'dart:collection' show Queue; 9 import 'dart:collection' show Queue;
10 10
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 fileUri = uri; 77 fileUri = uri;
78 break; 78 break;
79 } 79 }
80 } 80 }
81 LibraryBuilder library = 81 LibraryBuilder library =
82 target.createLibraryBuilder(uri, fileUri, isPatch); 82 target.createLibraryBuilder(uri, fileUri, isPatch);
83 if (uri.scheme == "dart" && uri.path == "core") { 83 if (uri.scheme == "dart" && uri.path == "core") {
84 coreLibrary = library; 84 coreLibrary = library;
85 target.loadExtraRequiredLibraries(this); 85 target.loadExtraRequiredLibraries(this);
86 } 86 }
87 if (target.backendTarget.mayDefineRestrictedType(uri)) {
88 library.mayImplementRestrictedTypes = true;
89 }
87 if (uri.scheme == "dart") { 90 if (uri.scheme == "dart") {
88 target.readPatchFiles(library); 91 target.readPatchFiles(library);
89 } 92 }
90 first ??= library; 93 first ??= library;
91 if (library.loader == this) { 94 if (library.loader == this) {
92 unparsedLibraries.addLast(library); 95 unparsedLibraries.addLast(library);
93 } 96 }
94 return library; 97 return library;
95 }); 98 });
96 if (accessor != null && 99 if (accessor != null &&
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 Builder getDuplicatedFieldInitializerError() { 185 Builder getDuplicatedFieldInitializerError() {
183 return target.getDuplicatedFieldInitializerError(this); 186 return target.getDuplicatedFieldInitializerError(this);
184 } 187 }
185 188
186 Builder getNativeAnnotation() => target.getNativeAnnotation(this); 189 Builder getNativeAnnotation() => target.getNativeAnnotation(this);
187 } 190 }
188 191
189 String format(double d, int fractionDigits, int width) { 192 String format(double d, int fractionDigits, int width) {
190 return d.toStringAsFixed(fractionDigits).padLeft(width); 193 return d.toStringAsFixed(fractionDigits).padLeft(width);
191 } 194 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698