Index: pkg/front_end/lib/src/incremental/file_state.dart |
diff --git a/pkg/front_end/lib/src/incremental/file_state.dart b/pkg/front_end/lib/src/incremental/file_state.dart |
index f6cc92ef3cf17427fee9bb8f06d4ae9e02845786..c95ac24b2307c0debee439b44f584a2b154147ad 100644 |
--- a/pkg/front_end/lib/src/incremental/file_state.dart |
+++ b/pkg/front_end/lib/src/incremental/file_state.dart |
@@ -281,6 +281,10 @@ class FileSystemState { |
/// contain `file:*` URIs as keys. |
final Map<Uri, FileState> _fileUriToFile = {}; |
+ /// The set of absolute URIs with the `dart` scheme that should be skipped. |
+ /// We do this when we use SDK outline instead of compiling SDK sources. |
+ final Set<Uri> skipSdkLibraries = new Set<Uri>(); |
+ |
FileSystemState(this._byteStore, this.fileSystem, this.uriTranslator, |
this._salt, this._newFileFn); |
@@ -333,6 +337,11 @@ class FileSystemState { |
/// |
/// The returned file has the last known state since it was last refreshed. |
Future<FileState> getFile(Uri absoluteUri) async { |
+ // We don't need to process SDK libraries if we have SDK outline. |
+ if (skipSdkLibraries.contains(absoluteUri)) { |
+ return null; |
+ } |
+ |
// Resolve the absolute URI into the absolute file URI. |
Uri fileUri; |
if (absoluteUri.isScheme('file')) { |