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

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

Issue 2036203005: Resynthesize CompilationUnitElement.types lazily. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 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 | « pkg/analyzer/lib/src/dart/element/element.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 ccca984b305500d4243a0c1d7119b26294ae6fe0..4c2db91a0ac6a953e8471671bccf0d5ba3e1ddae 100644
--- a/pkg/analyzer/lib/src/summary/resynthesize.dart
+++ b/pkg/analyzer/lib/src/summary/resynthesize.dart
@@ -1509,28 +1509,6 @@ class _UnitResynthesizer {
}
/**
- * Build the annotations for the given [element].
- */
- void buildAnnotations(
- ElementImpl element, List<UnlinkedConst> serializedAnnotations) {
- if (serializedAnnotations.isNotEmpty) {
- element.metadata = serializedAnnotations
- .map((a) => buildAnnotation(element, a))
- .toList();
- }
- }
-
- /**
- * Resynthesize a [ClassElement] and place it in [unitHolder].
- */
- void buildClass(UnlinkedClass serializedClass) {
- ClassElementImpl classElement =
- new ClassElementImpl.forSerialized(serializedClass, unit);
- classElement.hasBeenInferred = summaryResynthesizer.strongMode;
- unitHolder.addType(classElement);
- }
-
- /**
* Build the documentation for the given [element]. Does nothing if
* [serializedDocumentationComment] is `null`.
*/
@@ -1601,17 +1579,6 @@ class _UnitResynthesizer {
}
/**
- * Resynthesize a [FieldElement].
- */
- void buildField(ClassElementImpl enclosingClass,
- UnlinkedVariable serializedVariable, ElementHolder holder) {
- FieldElementImpl element = new FieldElementImpl.forSerializedFactory(
- serializedVariable, enclosingClass);
- holder.addField(element);
- buildImplicitAccessors(element, holder);
- }
-
- /**
* Build the implicit getter and setter associated with [element], and place
* them in [holder].
*/
@@ -1898,10 +1865,8 @@ class _UnitResynthesizer {
* contained in it.
*/
void populateUnit() {
- unlinkedUnit.classes.forEach(buildClass);
unlinkedUnit.enums.forEach(buildEnum);
unit.enums = unitHolder.enums;
- unit.types = unitHolder.types;
}
Expression _buildConstExpression(ElementImpl context, UnlinkedConst uc) {
« no previous file with comments | « pkg/analyzer/lib/src/dart/element/element.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698