Skip to content

Commit f670a46

Browse files
committed
Rename UnlinkedConst -> UnlinkedExpr
This is purely a nomenclature change to avoid confusion, since these data structures are used for all expressions that appear in summaries, regardless of whether they are const. [email protected], [email protected] Review URL: https://codereview.chromium.org/2508343002 .
1 parent 985d03d commit f670a46

File tree

9 files changed

+2026
-2029
lines changed

9 files changed

+2026
-2029
lines changed

pkg/analyzer/lib/src/dart/element/element.dart

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2336,7 +2336,7 @@ abstract class ConstVariableElement
23362336
* If this element is resynthesized from the summary, return the unlinked
23372337
* initializer, otherwise return `null`.
23382338
*/
2339-
UnlinkedConst get _unlinkedConst;
2339+
UnlinkedExpr get _unlinkedConst;
23402340

23412341
/**
23422342
* Return a representation of the value of this variable, forcing the value
@@ -3129,7 +3129,7 @@ abstract class ElementImpl implements Element {
31293129
* Return annotations for the given [unlinkedConsts] in the [unit].
31303130
*/
31313131
List<ElementAnnotation> _buildAnnotations(
3132-
CompilationUnitElementImpl unit, List<UnlinkedConst> unlinkedConsts) {
3132+
CompilationUnitElementImpl unit, List<UnlinkedExpr> unlinkedConsts) {
31333133
int length = unlinkedConsts.length;
31343134
if (length != 0) {
31353135
List<ElementAnnotation> annotations = new List<ElementAnnotation>(length);
@@ -6811,7 +6811,7 @@ abstract class NonParameterVariableElementImpl extends VariableElementImpl {
68116811
/**
68126812
* Subclasses need this getter, see [ConstVariableElement._unlinkedConst].
68136813
*/
6814-
UnlinkedConst get _unlinkedConst => _unlinkedVariable?.initializer?.bodyExpr;
6814+
UnlinkedExpr get _unlinkedConst => _unlinkedVariable?.initializer?.bodyExpr;
68156815
}
68166816

68176817
/**
@@ -7178,7 +7178,7 @@ class ParameterElementImpl extends VariableElementImpl
71787178
/**
71797179
* Subclasses need this getter, see [ConstVariableElement._unlinkedConst].
71807180
*/
7181-
UnlinkedConst get _unlinkedConst => _unlinkedParam?.initializer?.bodyExpr;
7181+
UnlinkedExpr get _unlinkedConst => _unlinkedParam?.initializer?.bodyExpr;
71827182

71837183
@override
71847184
accept(ElementVisitor visitor) => visitor.visitParameterElement(this);
@@ -7760,14 +7760,14 @@ abstract class PropertyInducingElementImpl
77607760
*/
77617761
abstract class ResynthesizerContext {
77627762
/**
7763-
* Build [ElementAnnotationImpl] for the given [UnlinkedConst].
7763+
* Build [ElementAnnotationImpl] for the given [UnlinkedExpr].
77647764
*/
7765-
ElementAnnotationImpl buildAnnotation(ElementImpl context, UnlinkedConst uc);
7765+
ElementAnnotationImpl buildAnnotation(ElementImpl context, UnlinkedExpr uc);
77667766

77677767
/**
7768-
* Build [Expression] for the given [UnlinkedConst].
7768+
* Build [Expression] for the given [UnlinkedExpr].
77697769
*/
7770-
Expression buildExpression(ElementImpl context, UnlinkedConst uc);
7770+
Expression buildExpression(ElementImpl context, UnlinkedExpr uc);
77717771

77727772
/**
77737773
* Build explicit top-level property accessors.

0 commit comments

Comments
 (0)