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

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

Issue 1567583002: Tests for SummarySdkAnalysisContext. (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/resynthesize.dart
diff --git a/pkg/analyzer/lib/src/summary/resynthesize.dart b/pkg/analyzer/lib/src/summary/resynthesize.dart
index b66088678d103aca057461aad318c646fc87c135..00379a090a1c08bfcf5be7279cacd6a25ec7d757 100644
--- a/pkg/analyzer/lib/src/summary/resynthesize.dart
+++ b/pkg/analyzer/lib/src/summary/resynthesize.dart
@@ -118,8 +118,8 @@ class SummaryResynthesizer extends ElementResynthesizer {
];
Source librarySource = _getSource(uri);
for (UnlinkedPart part in serializedUnits[0].publicNamespace.parts) {
- String partAbsUri =
- sourceFactory.resolveUri(librarySource, part.uri).uri.toString();
+ Source partSource = sourceFactory.resolveUri(librarySource, part.uri);
+ String partAbsUri = partSource.uri.toString();
serializedUnits.add(getUnlinkedSummary(partAbsUri));
}
_LibraryResynthesizer libraryResynthesizer = new _LibraryResynthesizer(
@@ -703,7 +703,8 @@ class _LibraryResynthesizer {
if (type.paramReference != 0) {
// TODO(paulberry): make this work for generic methods.
return currentTypeParameters[
- currentTypeParameters.length - type.paramReference].type;
+ currentTypeParameters.length - type.paramReference]
+ .type;
} else {
// TODO(paulberry): handle references to things other than classes (note:
// this should only occur in the case of erroneous code).
@@ -727,8 +728,8 @@ class _LibraryResynthesizer {
if (referenceResolution.unit != 0) {
UnlinkedUnit referencedLibraryDefiningUnit =
summaryResynthesizer.getUnlinkedSummary(referencedLibraryUri);
- String uri = referencedLibraryDefiningUnit.publicNamespace.parts[
- referenceResolution.unit - 1].uri;
+ String uri = referencedLibraryDefiningUnit
+ .publicNamespace.parts[referenceResolution.unit - 1].uri;
Source partSource = summaryResynthesizer.sourceFactory
.resolveUri(referencedLibrarySource, uri);
partUri = partSource.uri.toString();
@@ -743,8 +744,10 @@ class _LibraryResynthesizer {
} else {
referencedLibraryUri = librarySource.uri.toString();
if (referenceResolution.unit != 0) {
- String uri = unlinkedUnits[0].publicNamespace.parts[
- referenceResolution.unit - 1].uri;
+ String uri = unlinkedUnits[0]
+ .publicNamespace
+ .parts[referenceResolution.unit - 1]
+ .uri;
Source partSource =
summaryResynthesizer.sourceFactory.resolveUri(librarySource, uri);
partUri = partSource.uri.toString();
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/summary/summary_sdk.dart » ('j') | pkg/analyzer/test/src/summary/summary_sdk_test.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698