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

Unified Diff: pkg/analyzer/lib/src/summary/summarize_elements.dart

Issue 1576743002: Create a prelinker for summaries. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 11 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
Index: pkg/analyzer/lib/src/summary/summarize_elements.dart
diff --git a/pkg/analyzer/lib/src/summary/summarize_elements.dart b/pkg/analyzer/lib/src/summary/summarize_elements.dart
index c47d2a0f9c3a72ed90ba1c3d000f0192e29df29c..c32b501d92901b44629998bc8939b9551b7cacc7 100644
--- a/pkg/analyzer/lib/src/summary/summarize_elements.dart
+++ b/pkg/analyzer/lib/src/summary/summarize_elements.dart
@@ -731,11 +731,13 @@ class _LibrarySerializer {
int serializeUnresolvedReference() {
// TODO(paulberry): in order for relinking to work, we need to record the
// name and prefix of the unresolved symbol. This is not (yet) encoded in
- // the element model.
+ // the element model. For the moment we use a name that can't possibly
+ // ever exist.
if (unresolvedReferenceIndex == null) {
assert(unlinkedReferences.length == prelinkedReferences.length);
unresolvedReferenceIndex = unlinkedReferences.length;
- unlinkedReferences.add(encodeUnlinkedReference(ctx));
+ unlinkedReferences
+ .add(encodeUnlinkedReference(ctx, name: '*unresolved*'));
prelinkedReferences.add(encodePrelinkedReference(ctx,
kind: PrelinkedReferenceKind.unresolved));
}

Powered by Google App Engine
This is Rietveld 408576698