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

Unified Diff: pkg/analyzer/tool/summary/idl.dart

Issue 1543403002: Create a section of the summary for public namespace information. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years 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 | « pkg/analyzer/test/src/summary/summary_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/tool/summary/idl.dart
diff --git a/pkg/analyzer/tool/summary/idl.dart b/pkg/analyzer/tool/summary/idl.dart
index 8ac44c98f3e4737b30cac83aa64b865ee1c66db1..0b964ca80d507719ee38c96dcc04c42655928845 100644
--- a/pkg/analyzer/tool/summary/idl.dart
+++ b/pkg/analyzer/tool/summary/idl.dart
@@ -542,6 +542,57 @@ class UnlinkedPart {
}
/**
+ * Unlinked summary information about a specific name contributed by a
+ * compilation unit to a library's public namespace.
+ *
+ * TODO(paulberry): add a count of generic parameters, so that resynthesis
+ * doesn't have to peek into the library to obtain this info.
+ *
+ * TODO(paulberry): for classes, add info about static members and
+ * constructors, since this will be needed to prelink info about constants.
+ *
+ * TODO(paulberry): some of this information is redundant with information
+ * elsewhere in the summary. Consider reducing the redundancy to reduce
+ * summary size.
+ */
+class UnlinkedPublicName {
+ /**
+ * The name itself.
+ */
+ String name;
+
+ /**
+ * The kind of object referred to by the name.
+ */
+ PrelinkedReferenceKind kind;
+}
+
+/**
+ * Unlinked summary information about what a compilation unit contributes to a
+ * library's public namespace. This is the subset of [UnlinkedUnit] that is
+ * required from dependent libraries in order to perform prelinking.
+ */
+class UnlinkedPublicNamespace {
+ /**
+ * Public names defined in the compilation unit.
+ *
+ * TODO(paulberry): consider sorting these names to reduce unnecessary
+ * relinking.
+ */
+ List<UnlinkedPublicName> names;
+
+ /**
+ * Export declarations in the compilation unit.
+ */
+ List<UnlinkedExport> exports;
+
+ /**
+ * Part declarations in the compilation unit.
+ */
+ List<UnlinkedPart> parts;
+}
+
+/**
* Unlinked summary information about a name referred to in one library that
* might be defined in another.
*/
@@ -655,6 +706,11 @@ class UnlinkedUnit {
String libraryName;
/**
+ * Unlinked public namespace of this compilation unit.
+ */
+ UnlinkedPublicNamespace publicNamespace;
+
+ /**
* Top level and prefixed names referred to by this compilation unit. The
* zeroth element of this array is always populated and always represents a
* reference to the pseudo-type "dynamic".
@@ -678,21 +734,11 @@ class UnlinkedUnit {
List<UnlinkedExecutable> executables;
/**
- * Export declarations in the compilation unit.
- */
- List<UnlinkedExport> exports;
-
- /**
* Import declarations in the compilation unit.
*/
List<UnlinkedImport> imports;
/**
- * Part declarations in the compilation unit.
- */
- List<UnlinkedPart> parts;
-
- /**
* Typedefs declared in the compilation unit.
*/
List<UnlinkedTypedef> typedefs;
« no previous file with comments | « pkg/analyzer/test/src/summary/summary_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698