Make visibleLength/visibleOffset informative.

These summary fields are related to source offsets, so they are
affected by minute changes to the source code that don't affect its
API; therefore they should be marked as "@informative" so that they
don't appear in API summaries.

R=scheglov@google.com

Review URL: https://codereview.chromium.org/2432183003 .
This commit is contained in:
Paul Berry 2016-10-19 14:24:42 -07:00
parent 4729ba0055
commit 84ec7f01c0
2 changed files with 4 additions and 2 deletions

View file

@ -5370,6 +5370,8 @@ class UnlinkedExecutableBuilder extends Object with _UnlinkedExecutableMixin imp
_redirectedConstructor?.flushInformative();
_returnType?.flushInformative();
_typeParameters?.forEach((b) => b.flushInformative());
_visibleLength = null;
_visibleOffset = null;
}
/**
@ -5430,8 +5432,6 @@ class UnlinkedExecutableBuilder extends Object with _UnlinkedExecutableMixin imp
x?.collectApiSignature(signature);
}
}
signature.addInt(this._visibleLength ?? 0);
signature.addInt(this._visibleOffset ?? 0);
signature.addInt(this._constCycleSlot ?? 0);
signature.addBool(this._bodyExpr != null);
this._bodyExpr?.collectApiSignature(signature);

View file

@ -1926,12 +1926,14 @@ abstract class UnlinkedExecutable extends base.SummaryClass {
/**
* If a local function, the length of the visible range; zero otherwise.
*/
@informative
@Id(20)
int get visibleLength;
/**
* If a local function, the beginning of the visible range; zero otherwise.
*/
@informative
@Id(21)
int get visibleOffset;
}