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

Unified Diff: pkg/front_end/lib/src/incremental/format.dart

Issue 2940673002: Store also 'hasMixinApplication' flag with UnlinkedUnit. (Closed)
Patch Set: Created 3 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 | « no previous file | pkg/front_end/test/src/incremental/format_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/front_end/lib/src/incremental/format.dart
diff --git a/pkg/front_end/lib/src/incremental/format.dart b/pkg/front_end/lib/src/incremental/format.dart
index 9ebefd9e90fb0633fd61010a9b438a11fc2d5488..f4b5cb15f6b54d2edb161ac745f17db021f37642 100644
--- a/pkg/front_end/lib/src/incremental/format.dart
+++ b/pkg/front_end/lib/src/incremental/format.dart
@@ -124,6 +124,9 @@ abstract class UnlinkedUnit {
/// Export directives in the compilation unit.
List<UnlinkedNamespaceDirective> get exports;
+ /// Whether the unit has a mixin application.
+ bool get hasMixinApplication;
+
/// Import directives in the compilation unit.
List<UnlinkedNamespaceDirective> get imports;
@@ -137,21 +140,28 @@ class UnlinkedUnitBuilder {
List<UnlinkedNamespaceDirectiveBuilder> _imports;
List<UnlinkedNamespaceDirectiveBuilder> _exports;
List<UnlinkedNamespaceDirectiveBuilder> _parts;
+ bool _hasMixinApplication;
UnlinkedUnitBuilder(
{List<int> apiSignature,
List<UnlinkedNamespaceDirectiveBuilder> imports,
List<UnlinkedNamespaceDirectiveBuilder> exports,
- List<UnlinkedNamespaceDirectiveBuilder> parts})
+ List<UnlinkedNamespaceDirectiveBuilder> parts,
+ bool hasMixinApplication})
: _apiSignature = apiSignature,
_imports = imports,
_exports = exports,
- _parts = parts;
+ _parts = parts,
+ _hasMixinApplication = hasMixinApplication;
void set exports(List<UnlinkedNamespaceDirectiveBuilder> value) {
this._exports = value;
}
+ void set hasMixinApplication(bool value) {
+ this._hasMixinApplication = value;
+ }
+
void set imports(List<UnlinkedNamespaceDirectiveBuilder> value) {
this._imports = value;
}
@@ -194,6 +204,9 @@ class UnlinkedUnitBuilder {
if (offset_parts != null) {
fbBuilder.addOffset(3, offset_parts);
}
+ if (_hasMixinApplication == true) {
+ fbBuilder.addBool(4, _hasMixinApplication);
+ }
return fbBuilder.endTable();
}
}
@@ -273,6 +286,7 @@ class _UnlinkedUnitImpl implements UnlinkedUnit {
List<UnlinkedNamespaceDirective> _imports;
List<UnlinkedNamespaceDirective> _exports;
List<UnlinkedNamespaceDirective> _parts;
+ bool _hasMixinApplication;
_UnlinkedUnitImpl(this._bc, this._bcOffset);
@@ -292,6 +306,13 @@ class _UnlinkedUnitImpl implements UnlinkedUnit {
}
@override
+ bool get hasMixinApplication {
+ _hasMixinApplication ??=
+ const fb.BoolReader().vTableGet(_bc, _bcOffset, 4, false);
+ return _hasMixinApplication;
+ }
+
+ @override
List<UnlinkedNamespaceDirective> get imports {
_imports ??= const fb.ListReader<UnlinkedNamespaceDirective>(
const _UnlinkedNamespaceDirectiveReader())
« no previous file with comments | « no previous file | pkg/front_end/test/src/incremental/format_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698