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

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

Issue 1621763002: Use the explicit string 'dynamic' to refer to dynamic in 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
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/summary/prelink.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/summary/format.dart
diff --git a/pkg/analyzer/lib/src/summary/format.dart b/pkg/analyzer/lib/src/summary/format.dart
index 0a771c25c549b9e9acace51ee2d84a462fdf22a0..ab62062d4b44ba972cec1bdcc788b3cded753796 100644
--- a/pkg/analyzer/lib/src/summary/format.dart
+++ b/pkg/analyzer/lib/src/summary/format.dart
@@ -447,12 +447,6 @@ class EntityRefBuilder extends Object with _EntityRefMixin implements EntityRef
/**
* Index into [UnlinkedUnit.references] for the entity being referred to, or
* zero if this is a reference to a type parameter.
- *
- * Note that since zero is also a valid index into
- * [UnlinkedUnit.references], we cannot distinguish between references to
- * type parameters and references to other entities by checking [reference]
- * against zero. To distinguish between references to type parameters and
- * references to other entities, check whether [paramReference] is zero.
*/
void set reference(int _value) {
assert(!_finished);
@@ -549,12 +543,6 @@ abstract class EntityRef extends base.SummaryClass {
/**
* Index into [UnlinkedUnit.references] for the entity being referred to, or
* zero if this is a reference to a type parameter.
- *
- * Note that since zero is also a valid index into
- * [UnlinkedUnit.references], we cannot distinguish between references to
- * type parameters and references to other entities by checking [reference]
- * against zero. To distinguish between references to type parameters and
- * references to other entities, check whether [paramReference] is zero.
*/
int get reference;
@@ -1252,8 +1240,8 @@ class LinkedReferenceBuilder extends Object with _LinkedReferenceMixin implement
/**
* If this [LinkedReference] doesn't have an associated [UnlinkedReference],
- * name of the entity being referred to. The empty string refers to the
- * pseudo-type `dynamic`.
+ * name of the entity being referred to. For the pseudo-type `dynamic`, the
+ * string is "dynamic".
*/
void set name(String _value) {
assert(!_finished);
@@ -1327,8 +1315,8 @@ abstract class LinkedReference extends base.SummaryClass {
/**
* If this [LinkedReference] doesn't have an associated [UnlinkedReference],
- * name of the entity being referred to. The empty string refers to the
- * pseudo-type `dynamic`.
+ * name of the entity being referred to. For the pseudo-type `dynamic`, the
+ * string is "dynamic".
*/
String get name;
}
@@ -4661,8 +4649,8 @@ class UnlinkedReferenceBuilder extends Object with _UnlinkedReferenceMixin imple
String get name => _name ??= '';
/**
- * Name of the entity being referred to. The empty string refers to the
- * pseudo-type `dynamic`.
+ * Name of the entity being referred to. For the pseudo-type `dynamic`, the
+ * string is "dynamic".
*/
void set name(String _value) {
assert(!_finished);
@@ -4715,8 +4703,8 @@ class UnlinkedReferenceBuilder extends Object with _UnlinkedReferenceMixin imple
abstract class UnlinkedReference extends base.SummaryClass {
/**
- * Name of the entity being referred to. The empty string refers to the
- * pseudo-type `dynamic`.
+ * Name of the entity being referred to. For the pseudo-type `dynamic`, the
+ * string is "dynamic".
*/
String get name;
@@ -5225,8 +5213,10 @@ class UnlinkedUnitBuilder extends Object with _UnlinkedUnitMixin implements Unli
/**
* 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".
+ * zeroth element of this array is always populated and is used to represent
+ * the absence of a reference in places where a reference is optional (for
+ * example [UnlinkedReference.prefixReference or
+ * UnlinkedImport.prefixReference]).
*/
void set references(List<UnlinkedReferenceBuilder> _value) {
assert(!_finished);
@@ -5480,8 +5470,10 @@ abstract class UnlinkedUnit extends base.SummaryClass {
/**
* 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".
+ * zeroth element of this array is always populated and is used to represent
+ * the absence of a reference in places where a reference is optional (for
+ * example [UnlinkedReference.prefixReference or
+ * UnlinkedImport.prefixReference]).
*/
List<UnlinkedReference> get references;
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/summary/prelink.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698