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

Unified Diff: pkg/analyzer/lib/src/task/dart.dart

Issue 1166983005: Ensure types are resolved for combined import/export closures. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 6 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 | « no previous file | pkg/analyzer/test/src/task/dart_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/task/dart.dart
diff --git a/pkg/analyzer/lib/src/task/dart.dart b/pkg/analyzer/lib/src/task/dart.dart
index dde0ebce7e37ca7e25abbe9850eb81508fc29a3a..8809da3d8e0960276f1aadbe7917453ee5de3912 100644
--- a/pkg/analyzer/lib/src/task/dart.dart
+++ b/pkg/analyzer/lib/src/task/dart.dart
@@ -172,6 +172,15 @@ final ListResultDescriptor<AnalysisError> HINTS =
'HINT_ERRORS', AnalysisError.NO_ERRORS);
/**
+ * The sources representing the combined import/export closure of a library.
+ * The [Source]s include only library sources, not their units.
+ *
+ * The result is only available for [Source]s representing a library.
+ */
+final ListResultDescriptor<Source> IMPORT_EXPORT_SOURCE_CLOSURE =
+ new ListResultDescriptor<Source>('IMPORT_EXPORT_SOURCE_CLOSURE', null);
+
+/**
* The sources representing the import closure of a library.
* The [Source]s include only library sources, not their units.
*
@@ -1576,10 +1585,10 @@ class BuildSourceClosuresTask extends SourceBasedAnalysisTask {
* The task descriptor describing this kind of task.
*/
static final TaskDescriptor DESCRIPTOR = new TaskDescriptor(
- 'BuildExportSourceClosureTask', createTask, buildInputs,
- <ResultDescriptor>[
+ 'BuildSourceClosuresTask', createTask, buildInputs, <ResultDescriptor>[
IMPORT_SOURCE_CLOSURE,
EXPORT_SOURCE_CLOSURE,
+ IMPORT_EXPORT_SOURCE_CLOSURE,
IS_CLIENT
]);
@@ -1601,6 +1610,7 @@ class BuildSourceClosuresTask extends SourceBasedAnalysisTask {
//
outputs[IMPORT_SOURCE_CLOSURE] = importClosure;
outputs[EXPORT_SOURCE_CLOSURE] = exportClosure;
+ outputs[IMPORT_EXPORT_SOURCE_CLOSURE] = importExportClosure;
outputs[IS_CLIENT] = importExportClosure.contains(htmlSource);
}
@@ -2841,11 +2851,11 @@ class ResolveLibraryTypeNamesTask extends SourceBasedAnalysisTask {
static Map<String, TaskInput> buildInputs(Source libSource) {
return <String, TaskInput>{
LIBRARY_INPUT: LIBRARY_ELEMENT4.of(libSource),
- 'resolvedUnits': IMPORT_SOURCE_CLOSURE
+ 'resolvedUnits': IMPORT_EXPORT_SOURCE_CLOSURE
.of(libSource)
.toMapOf(UNITS)
.toFlattenList((Source library, Source unit) =>
- RESOLVED_UNIT4.of(new LibrarySpecificUnit(library, unit)))
+ RESOLVED_UNIT4.of(new LibrarySpecificUnit(library, unit))),
};
}
« no previous file with comments | « no previous file | pkg/analyzer/test/src/task/dart_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698