| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 // | 4 // |
| 5 // This file has been automatically generated. Please do not edit it manually. | 5 // This file has been automatically generated. Please do not edit it manually. |
| 6 // To regenerate the file, use the script "pkg/analyzer/tool/generate_files". | 6 // To regenerate the file, use the script "pkg/analyzer/tool/generate_files". |
| 7 | 7 |
| 8 library analyzer.src.summary.format; | 8 library analyzer.src.summary.format; |
| 9 | 9 |
| 10 import 'base.dart' as base; | 10 import 'base.dart' as base; |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 } | 140 } |
| 141 } | 141 } |
| 142 | 142 |
| 143 class LinkedDependencyBuilder extends Object with _LinkedDependencyMixin impleme
nts LinkedDependency { | 143 class LinkedDependencyBuilder extends Object with _LinkedDependencyMixin impleme
nts LinkedDependency { |
| 144 bool _finished = false; | 144 bool _finished = false; |
| 145 | 145 |
| 146 String _uri; | 146 String _uri; |
| 147 List<String> _parts; | 147 List<String> _parts; |
| 148 | 148 |
| 149 @override | 149 @override |
| 150 String get uri => _uri ?? ''; | 150 String get uri => _uri ??= ''; |
| 151 | 151 |
| 152 /** | 152 /** |
| 153 * The relative URI of the dependent library. This URI is relative to the | 153 * The relative URI of the dependent library. This URI is relative to the |
| 154 * importing library, even if there are intervening `export` declarations. | 154 * importing library, even if there are intervening `export` declarations. |
| 155 * So, for example, if `a.dart` imports `b/c.dart` and `b/c.dart` exports | 155 * So, for example, if `a.dart` imports `b/c.dart` and `b/c.dart` exports |
| 156 * `d/e.dart`, the URI listed for `a.dart`'s dependency on `e.dart` will be | 156 * `d/e.dart`, the URI listed for `a.dart`'s dependency on `e.dart` will be |
| 157 * `b/d/e.dart`. | 157 * `b/d/e.dart`. |
| 158 */ | 158 */ |
| 159 void set uri(String _value) { | 159 void set uri(String _value) { |
| 160 assert(!_finished); | 160 assert(!_finished); |
| 161 _uri = _value; | 161 _uri = _value; |
| 162 } | 162 } |
| 163 | 163 |
| 164 @override | 164 @override |
| 165 List<String> get parts => _parts ?? const <String>[]; | 165 List<String> get parts => _parts ??= <String>[]; |
| 166 | 166 |
| 167 /** | 167 /** |
| 168 * URI for the compilation units listed in the library's `part` declarations. | 168 * URI for the compilation units listed in the library's `part` declarations. |
| 169 * These URIs are relative to the importing library. | 169 * These URIs are relative to the importing library. |
| 170 */ | 170 */ |
| 171 void set parts(List<String> _value) { | 171 void set parts(List<String> _value) { |
| 172 assert(!_finished); | 172 assert(!_finished); |
| 173 _parts = _value; | 173 _parts = _value; |
| 174 } | 174 } |
| 175 | 175 |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 259 | 259 |
| 260 class LinkedExportNameBuilder extends Object with _LinkedExportNameMixin impleme
nts LinkedExportName { | 260 class LinkedExportNameBuilder extends Object with _LinkedExportNameMixin impleme
nts LinkedExportName { |
| 261 bool _finished = false; | 261 bool _finished = false; |
| 262 | 262 |
| 263 String _name; | 263 String _name; |
| 264 int _dependency; | 264 int _dependency; |
| 265 int _unit; | 265 int _unit; |
| 266 ReferenceKind _kind; | 266 ReferenceKind _kind; |
| 267 | 267 |
| 268 @override | 268 @override |
| 269 String get name => _name ?? ''; | 269 String get name => _name ??= ''; |
| 270 | 270 |
| 271 /** | 271 /** |
| 272 * Name of the exported entity. TODO(paulberry): do we include the trailing | 272 * Name of the exported entity. TODO(paulberry): do we include the trailing |
| 273 * '=' for a setter? | 273 * '=' for a setter? |
| 274 */ | 274 */ |
| 275 void set name(String _value) { | 275 void set name(String _value) { |
| 276 assert(!_finished); | 276 assert(!_finished); |
| 277 _name = _value; | 277 _name = _value; |
| 278 } | 278 } |
| 279 | 279 |
| 280 @override | 280 @override |
| 281 int get dependency => _dependency ?? 0; | 281 int get dependency => _dependency ??= 0; |
| 282 | 282 |
| 283 /** | 283 /** |
| 284 * Index into [LinkedLibrary.dependencies] for the library in which the | 284 * Index into [LinkedLibrary.dependencies] for the library in which the |
| 285 * entity is defined. | 285 * entity is defined. |
| 286 */ | 286 */ |
| 287 void set dependency(int _value) { | 287 void set dependency(int _value) { |
| 288 assert(!_finished); | 288 assert(!_finished); |
| 289 assert(_value == null || _value >= 0); | 289 assert(_value == null || _value >= 0); |
| 290 _dependency = _value; | 290 _dependency = _value; |
| 291 } | 291 } |
| 292 | 292 |
| 293 @override | 293 @override |
| 294 int get unit => _unit ?? 0; | 294 int get unit => _unit ??= 0; |
| 295 | 295 |
| 296 /** | 296 /** |
| 297 * Integer index indicating which unit in the exported library contains the | 297 * Integer index indicating which unit in the exported library contains the |
| 298 * definition of the entity. As with indices into [LinkedLibrary.units], | 298 * definition of the entity. As with indices into [LinkedLibrary.units], |
| 299 * zero represents the defining compilation unit, and nonzero values | 299 * zero represents the defining compilation unit, and nonzero values |
| 300 * represent parts in the order of the corresponding `part` declarations. | 300 * represent parts in the order of the corresponding `part` declarations. |
| 301 */ | 301 */ |
| 302 void set unit(int _value) { | 302 void set unit(int _value) { |
| 303 assert(!_finished); | 303 assert(!_finished); |
| 304 assert(_value == null || _value >= 0); | 304 assert(_value == null || _value >= 0); |
| 305 _unit = _value; | 305 _unit = _value; |
| 306 } | 306 } |
| 307 | 307 |
| 308 @override | 308 @override |
| 309 ReferenceKind get kind => _kind ?? ReferenceKind.classOrEnum; | 309 ReferenceKind get kind => _kind ??= ReferenceKind.classOrEnum; |
| 310 | 310 |
| 311 /** | 311 /** |
| 312 * The kind of the entity being referred to. | 312 * The kind of the entity being referred to. |
| 313 */ | 313 */ |
| 314 void set kind(ReferenceKind _value) { | 314 void set kind(ReferenceKind _value) { |
| 315 assert(!_finished); | 315 assert(!_finished); |
| 316 _kind = _value; | 316 _kind = _value; |
| 317 } | 317 } |
| 318 | 318 |
| 319 LinkedExportNameBuilder({String name, int dependency, int unit, ReferenceKind
kind}) | 319 LinkedExportNameBuilder({String name, int dependency, int unit, ReferenceKind
kind}) |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 433 class LinkedLibraryBuilder extends Object with _LinkedLibraryMixin implements Li
nkedLibrary { | 433 class LinkedLibraryBuilder extends Object with _LinkedLibraryMixin implements Li
nkedLibrary { |
| 434 bool _finished = false; | 434 bool _finished = false; |
| 435 | 435 |
| 436 List<LinkedUnitBuilder> _units; | 436 List<LinkedUnitBuilder> _units; |
| 437 List<LinkedDependencyBuilder> _dependencies; | 437 List<LinkedDependencyBuilder> _dependencies; |
| 438 List<int> _importDependencies; | 438 List<int> _importDependencies; |
| 439 List<LinkedExportNameBuilder> _exportNames; | 439 List<LinkedExportNameBuilder> _exportNames; |
| 440 int _numPrelinkedDependencies; | 440 int _numPrelinkedDependencies; |
| 441 | 441 |
| 442 @override | 442 @override |
| 443 List<LinkedUnit> get units => _units ?? const <LinkedUnit>[]; | 443 List<LinkedUnitBuilder> get units => _units ??= <LinkedUnitBuilder>[]; |
| 444 | 444 |
| 445 /** | 445 /** |
| 446 * The linked summary of all the compilation units constituting the | 446 * The linked summary of all the compilation units constituting the |
| 447 * library. The summary of the defining compilation unit is listed first, | 447 * library. The summary of the defining compilation unit is listed first, |
| 448 * followed by the summary of each part, in the order of the `part` | 448 * followed by the summary of each part, in the order of the `part` |
| 449 * declarations in the defining compilation unit. | 449 * declarations in the defining compilation unit. |
| 450 */ | 450 */ |
| 451 void set units(List<LinkedUnitBuilder> _value) { | 451 void set units(List<LinkedUnitBuilder> _value) { |
| 452 assert(!_finished); | 452 assert(!_finished); |
| 453 _units = _value; | 453 _units = _value; |
| 454 } | 454 } |
| 455 | 455 |
| 456 @override | 456 @override |
| 457 List<LinkedDependency> get dependencies => _dependencies ?? const <LinkedDepen
dency>[]; | 457 List<LinkedDependencyBuilder> get dependencies => _dependencies ??= <LinkedDep
endencyBuilder>[]; |
| 458 | 458 |
| 459 /** | 459 /** |
| 460 * The libraries that this library depends on (either via an explicit import | 460 * The libraries that this library depends on (either via an explicit import |
| 461 * statement or via the implicit dependencies on `dart:core` and | 461 * statement or via the implicit dependencies on `dart:core` and |
| 462 * `dart:async`). The first element of this array is a pseudo-dependency | 462 * `dart:async`). The first element of this array is a pseudo-dependency |
| 463 * representing the library itself (it is also used for "dynamic"). This is | 463 * representing the library itself (it is also used for "dynamic"). This is |
| 464 * followed by elements representing "prelinked" dependencies (direct imports | 464 * followed by elements representing "prelinked" dependencies (direct imports |
| 465 * and the transitive closure of exports). After the prelinked dependencies | 465 * and the transitive closure of exports). After the prelinked dependencies |
| 466 * are elements represent "linked" dependencies. | 466 * are elements represent "linked" dependencies. |
| 467 * | 467 * |
| 468 * A library is only included as a "linked" dependency if it is a true | 468 * A library is only included as a "linked" dependency if it is a true |
| 469 * dependency (e.g. a propagated or inferred type or constant value | 469 * dependency (e.g. a propagated or inferred type or constant value |
| 470 * implicitly refers to an element declared in the library) or | 470 * implicitly refers to an element declared in the library) or |
| 471 * anti-dependency (e.g. the result of type propagation or type inference | 471 * anti-dependency (e.g. the result of type propagation or type inference |
| 472 * depends on the lack of a certain declaration in the library). | 472 * depends on the lack of a certain declaration in the library). |
| 473 */ | 473 */ |
| 474 void set dependencies(List<LinkedDependencyBuilder> _value) { | 474 void set dependencies(List<LinkedDependencyBuilder> _value) { |
| 475 assert(!_finished); | 475 assert(!_finished); |
| 476 _dependencies = _value; | 476 _dependencies = _value; |
| 477 } | 477 } |
| 478 | 478 |
| 479 @override | 479 @override |
| 480 List<int> get importDependencies => _importDependencies ?? const <int>[]; | 480 List<int> get importDependencies => _importDependencies ??= <int>[]; |
| 481 | 481 |
| 482 /** | 482 /** |
| 483 * For each import in [UnlinkedUnit.imports], an index into [dependencies] | 483 * For each import in [UnlinkedUnit.imports], an index into [dependencies] |
| 484 * of the library being imported. | 484 * of the library being imported. |
| 485 */ | 485 */ |
| 486 void set importDependencies(List<int> _value) { | 486 void set importDependencies(List<int> _value) { |
| 487 assert(!_finished); | 487 assert(!_finished); |
| 488 assert(_value == null || _value.every((e) => e >= 0)); | 488 assert(_value == null || _value.every((e) => e >= 0)); |
| 489 _importDependencies = _value; | 489 _importDependencies = _value; |
| 490 } | 490 } |
| 491 | 491 |
| 492 @override | 492 @override |
| 493 List<LinkedExportName> get exportNames => _exportNames ?? const <LinkedExportN
ame>[]; | 493 List<LinkedExportNameBuilder> get exportNames => _exportNames ??= <LinkedExpor
tNameBuilder>[]; |
| 494 | 494 |
| 495 /** | 495 /** |
| 496 * Information about entities in the export namespace of the library that are | 496 * Information about entities in the export namespace of the library that are |
| 497 * not in the public namespace of the library (that is, entities that are | 497 * not in the public namespace of the library (that is, entities that are |
| 498 * brought into the namespace via `export` directives). | 498 * brought into the namespace via `export` directives). |
| 499 * | 499 * |
| 500 * Sorted by name. | 500 * Sorted by name. |
| 501 */ | 501 */ |
| 502 void set exportNames(List<LinkedExportNameBuilder> _value) { | 502 void set exportNames(List<LinkedExportNameBuilder> _value) { |
| 503 assert(!_finished); | 503 assert(!_finished); |
| 504 _exportNames = _value; | 504 _exportNames = _value; |
| 505 } | 505 } |
| 506 | 506 |
| 507 @override | 507 @override |
| 508 int get numPrelinkedDependencies => _numPrelinkedDependencies ?? 0; | 508 int get numPrelinkedDependencies => _numPrelinkedDependencies ??= 0; |
| 509 | 509 |
| 510 /** | 510 /** |
| 511 * The number of elements in [dependencies] which are not "linked" | 511 * The number of elements in [dependencies] which are not "linked" |
| 512 * dependencies (that is, the number of libraries in the direct imports plus | 512 * dependencies (that is, the number of libraries in the direct imports plus |
| 513 * the transitive closure of exports, plus the library itself). | 513 * the transitive closure of exports, plus the library itself). |
| 514 */ | 514 */ |
| 515 void set numPrelinkedDependencies(int _value) { | 515 void set numPrelinkedDependencies(int _value) { |
| 516 assert(!_finished); | 516 assert(!_finished); |
| 517 assert(_value == null || _value >= 0); | 517 assert(_value == null || _value >= 0); |
| 518 _numPrelinkedDependencies = _value; | 518 _numPrelinkedDependencies = _value; |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 689 class LinkedReferenceBuilder extends Object with _LinkedReferenceMixin implement
s LinkedReference { | 689 class LinkedReferenceBuilder extends Object with _LinkedReferenceMixin implement
s LinkedReference { |
| 690 bool _finished = false; | 690 bool _finished = false; |
| 691 | 691 |
| 692 int _dependency; | 692 int _dependency; |
| 693 ReferenceKind _kind; | 693 ReferenceKind _kind; |
| 694 int _unit; | 694 int _unit; |
| 695 int _numTypeParameters; | 695 int _numTypeParameters; |
| 696 String _name; | 696 String _name; |
| 697 | 697 |
| 698 @override | 698 @override |
| 699 int get dependency => _dependency ?? 0; | 699 int get dependency => _dependency ??= 0; |
| 700 | 700 |
| 701 /** | 701 /** |
| 702 * Index into [LinkedLibrary.dependencies] indicating which imported library | 702 * Index into [LinkedLibrary.dependencies] indicating which imported library |
| 703 * declares the entity being referred to. | 703 * declares the entity being referred to. |
| 704 */ | 704 */ |
| 705 void set dependency(int _value) { | 705 void set dependency(int _value) { |
| 706 assert(!_finished); | 706 assert(!_finished); |
| 707 assert(_value == null || _value >= 0); | 707 assert(_value == null || _value >= 0); |
| 708 _dependency = _value; | 708 _dependency = _value; |
| 709 } | 709 } |
| 710 | 710 |
| 711 @override | 711 @override |
| 712 ReferenceKind get kind => _kind ?? ReferenceKind.classOrEnum; | 712 ReferenceKind get kind => _kind ??= ReferenceKind.classOrEnum; |
| 713 | 713 |
| 714 /** | 714 /** |
| 715 * The kind of the entity being referred to. For the pseudo-type `dynamic`, | 715 * The kind of the entity being referred to. For the pseudo-type `dynamic`, |
| 716 * the kind is [ReferenceKind.classOrEnum]. | 716 * the kind is [ReferenceKind.classOrEnum]. |
| 717 */ | 717 */ |
| 718 void set kind(ReferenceKind _value) { | 718 void set kind(ReferenceKind _value) { |
| 719 assert(!_finished); | 719 assert(!_finished); |
| 720 _kind = _value; | 720 _kind = _value; |
| 721 } | 721 } |
| 722 | 722 |
| 723 @override | 723 @override |
| 724 int get unit => _unit ?? 0; | 724 int get unit => _unit ??= 0; |
| 725 | 725 |
| 726 /** | 726 /** |
| 727 * Integer index indicating which unit in the imported library contains the | 727 * Integer index indicating which unit in the imported library contains the |
| 728 * definition of the entity. As with indices into [LinkedLibrary.units], | 728 * definition of the entity. As with indices into [LinkedLibrary.units], |
| 729 * zero represents the defining compilation unit, and nonzero values | 729 * zero represents the defining compilation unit, and nonzero values |
| 730 * represent parts in the order of the corresponding `part` declarations. | 730 * represent parts in the order of the corresponding `part` declarations. |
| 731 */ | 731 */ |
| 732 void set unit(int _value) { | 732 void set unit(int _value) { |
| 733 assert(!_finished); | 733 assert(!_finished); |
| 734 assert(_value == null || _value >= 0); | 734 assert(_value == null || _value >= 0); |
| 735 _unit = _value; | 735 _unit = _value; |
| 736 } | 736 } |
| 737 | 737 |
| 738 @override | 738 @override |
| 739 int get numTypeParameters => _numTypeParameters ?? 0; | 739 int get numTypeParameters => _numTypeParameters ??= 0; |
| 740 | 740 |
| 741 /** | 741 /** |
| 742 * If the entity being referred to is generic, the number of type parameters | 742 * If the entity being referred to is generic, the number of type parameters |
| 743 * it accepts. Otherwise zero. | 743 * it accepts. Otherwise zero. |
| 744 */ | 744 */ |
| 745 void set numTypeParameters(int _value) { | 745 void set numTypeParameters(int _value) { |
| 746 assert(!_finished); | 746 assert(!_finished); |
| 747 assert(_value == null || _value >= 0); | 747 assert(_value == null || _value >= 0); |
| 748 _numTypeParameters = _value; | 748 _numTypeParameters = _value; |
| 749 } | 749 } |
| 750 | 750 |
| 751 @override | 751 @override |
| 752 String get name => _name ?? ''; | 752 String get name => _name ??= ''; |
| 753 | 753 |
| 754 /** | 754 /** |
| 755 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], | 755 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], |
| 756 * name of the entity being referred to. The empty string refers to the | 756 * name of the entity being referred to. The empty string refers to the |
| 757 * pseudo-type `dynamic`. | 757 * pseudo-type `dynamic`. |
| 758 */ | 758 */ |
| 759 void set name(String _value) { | 759 void set name(String _value) { |
| 760 assert(!_finished); | 760 assert(!_finished); |
| 761 _name = _value; | 761 _name = _value; |
| 762 } | 762 } |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 894 }; | 894 }; |
| 895 } | 895 } |
| 896 | 896 |
| 897 class LinkedUnitBuilder extends Object with _LinkedUnitMixin implements LinkedUn
it { | 897 class LinkedUnitBuilder extends Object with _LinkedUnitMixin implements LinkedUn
it { |
| 898 bool _finished = false; | 898 bool _finished = false; |
| 899 | 899 |
| 900 List<LinkedReferenceBuilder> _references; | 900 List<LinkedReferenceBuilder> _references; |
| 901 List<TypeRefBuilder> _types; | 901 List<TypeRefBuilder> _types; |
| 902 | 902 |
| 903 @override | 903 @override |
| 904 List<LinkedReference> get references => _references ?? const <LinkedReference>
[]; | 904 List<LinkedReferenceBuilder> get references => _references ??= <LinkedReferenc
eBuilder>[]; |
| 905 | 905 |
| 906 /** | 906 /** |
| 907 * Information about the resolution of references within the compilation | 907 * Information about the resolution of references within the compilation |
| 908 * unit. Each element of [UnlinkedUnit.references] has a corresponding | 908 * unit. Each element of [UnlinkedUnit.references] has a corresponding |
| 909 * element in this list (at the same index). If this list has additional | 909 * element in this list (at the same index). If this list has additional |
| 910 * elements beyond the number of elements in [UnlinkedUnit.references], those | 910 * elements beyond the number of elements in [UnlinkedUnit.references], those |
| 911 * additional elements are references that are only referred to implicitly | 911 * additional elements are references that are only referred to implicitly |
| 912 * (e.g. elements involved in inferred or propagated types). | 912 * (e.g. elements involved in inferred or propagated types). |
| 913 */ | 913 */ |
| 914 void set references(List<LinkedReferenceBuilder> _value) { | 914 void set references(List<LinkedReferenceBuilder> _value) { |
| 915 assert(!_finished); | 915 assert(!_finished); |
| 916 _references = _value; | 916 _references = _value; |
| 917 } | 917 } |
| 918 | 918 |
| 919 @override | 919 @override |
| 920 List<TypeRef> get types => _types ?? const <TypeRef>[]; | 920 List<TypeRefBuilder> get types => _types ??= <TypeRefBuilder>[]; |
| 921 | 921 |
| 922 /** | 922 /** |
| 923 * List associating slot ids found inside the unlinked summary for the | 923 * List associating slot ids found inside the unlinked summary for the |
| 924 * compilation unit with propagated and inferred types. | 924 * compilation unit with propagated and inferred types. |
| 925 */ | 925 */ |
| 926 void set types(List<TypeRefBuilder> _value) { | 926 void set types(List<TypeRefBuilder> _value) { |
| 927 assert(!_finished); | 927 assert(!_finished); |
| 928 _types = _value; | 928 _types = _value; |
| 929 } | 929 } |
| 930 | 930 |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1014 | 1014 |
| 1015 class SdkBundleBuilder extends Object with _SdkBundleMixin implements SdkBundle
{ | 1015 class SdkBundleBuilder extends Object with _SdkBundleMixin implements SdkBundle
{ |
| 1016 bool _finished = false; | 1016 bool _finished = false; |
| 1017 | 1017 |
| 1018 List<String> _linkedLibraryUris; | 1018 List<String> _linkedLibraryUris; |
| 1019 List<LinkedLibraryBuilder> _linkedLibraries; | 1019 List<LinkedLibraryBuilder> _linkedLibraries; |
| 1020 List<String> _unlinkedUnitUris; | 1020 List<String> _unlinkedUnitUris; |
| 1021 List<UnlinkedUnitBuilder> _unlinkedUnits; | 1021 List<UnlinkedUnitBuilder> _unlinkedUnits; |
| 1022 | 1022 |
| 1023 @override | 1023 @override |
| 1024 List<String> get linkedLibraryUris => _linkedLibraryUris ?? const <String>[]; | 1024 List<String> get linkedLibraryUris => _linkedLibraryUris ??= <String>[]; |
| 1025 | 1025 |
| 1026 /** | 1026 /** |
| 1027 * The list of URIs of items in [linkedLibraries], e.g. `dart:core`. | 1027 * The list of URIs of items in [linkedLibraries], e.g. `dart:core`. |
| 1028 */ | 1028 */ |
| 1029 void set linkedLibraryUris(List<String> _value) { | 1029 void set linkedLibraryUris(List<String> _value) { |
| 1030 assert(!_finished); | 1030 assert(!_finished); |
| 1031 _linkedLibraryUris = _value; | 1031 _linkedLibraryUris = _value; |
| 1032 } | 1032 } |
| 1033 | 1033 |
| 1034 @override | 1034 @override |
| 1035 List<LinkedLibrary> get linkedLibraries => _linkedLibraries ?? const <LinkedLi
brary>[]; | 1035 List<LinkedLibraryBuilder> get linkedLibraries => _linkedLibraries ??= <Linked
LibraryBuilder>[]; |
| 1036 | 1036 |
| 1037 /** | 1037 /** |
| 1038 * Linked libraries. | 1038 * Linked libraries. |
| 1039 */ | 1039 */ |
| 1040 void set linkedLibraries(List<LinkedLibraryBuilder> _value) { | 1040 void set linkedLibraries(List<LinkedLibraryBuilder> _value) { |
| 1041 assert(!_finished); | 1041 assert(!_finished); |
| 1042 _linkedLibraries = _value; | 1042 _linkedLibraries = _value; |
| 1043 } | 1043 } |
| 1044 | 1044 |
| 1045 @override | 1045 @override |
| 1046 List<String> get unlinkedUnitUris => _unlinkedUnitUris ?? const <String>[]; | 1046 List<String> get unlinkedUnitUris => _unlinkedUnitUris ??= <String>[]; |
| 1047 | 1047 |
| 1048 /** | 1048 /** |
| 1049 * The list of URIs of items in [unlinkedUnits], e.g. `dart:core/bool.dart`. | 1049 * The list of URIs of items in [unlinkedUnits], e.g. `dart:core/bool.dart`. |
| 1050 */ | 1050 */ |
| 1051 void set unlinkedUnitUris(List<String> _value) { | 1051 void set unlinkedUnitUris(List<String> _value) { |
| 1052 assert(!_finished); | 1052 assert(!_finished); |
| 1053 _unlinkedUnitUris = _value; | 1053 _unlinkedUnitUris = _value; |
| 1054 } | 1054 } |
| 1055 | 1055 |
| 1056 @override | 1056 @override |
| 1057 List<UnlinkedUnit> get unlinkedUnits => _unlinkedUnits ?? const <UnlinkedUnit>
[]; | 1057 List<UnlinkedUnitBuilder> get unlinkedUnits => _unlinkedUnits ??= <UnlinkedUni
tBuilder>[]; |
| 1058 | 1058 |
| 1059 /** | 1059 /** |
| 1060 * Unlinked information for the compilation units constituting the SDK. | 1060 * Unlinked information for the compilation units constituting the SDK. |
| 1061 */ | 1061 */ |
| 1062 void set unlinkedUnits(List<UnlinkedUnitBuilder> _value) { | 1062 void set unlinkedUnits(List<UnlinkedUnitBuilder> _value) { |
| 1063 assert(!_finished); | 1063 assert(!_finished); |
| 1064 _unlinkedUnits = _value; | 1064 _unlinkedUnits = _value; |
| 1065 } | 1065 } |
| 1066 | 1066 |
| 1067 SdkBundleBuilder({List<String> linkedLibraryUris, List<LinkedLibraryBuilder> l
inkedLibraries, List<String> unlinkedUnitUris, List<UnlinkedUnitBuilder> unlinke
dUnits}) | 1067 SdkBundleBuilder({List<String> linkedLibraryUris, List<LinkedLibraryBuilder> l
inkedLibraries, List<String> unlinkedUnitUris, List<UnlinkedUnitBuilder> unlinke
dUnits}) |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1195 | 1195 |
| 1196 class TypeRefBuilder extends Object with _TypeRefMixin implements TypeRef { | 1196 class TypeRefBuilder extends Object with _TypeRefMixin implements TypeRef { |
| 1197 bool _finished = false; | 1197 bool _finished = false; |
| 1198 | 1198 |
| 1199 int _slot; | 1199 int _slot; |
| 1200 int _reference; | 1200 int _reference; |
| 1201 int _paramReference; | 1201 int _paramReference; |
| 1202 List<TypeRefBuilder> _typeArguments; | 1202 List<TypeRefBuilder> _typeArguments; |
| 1203 | 1203 |
| 1204 @override | 1204 @override |
| 1205 int get slot => _slot ?? 0; | 1205 int get slot => _slot ??= 0; |
| 1206 | 1206 |
| 1207 /** | 1207 /** |
| 1208 * If this [TypeRef] is contained within [LinkedUnit.types], slot id (which | 1208 * If this [TypeRef] is contained within [LinkedUnit.types], slot id (which |
| 1209 * is unique within the compilation unit) identifying the target of type | 1209 * is unique within the compilation unit) identifying the target of type |
| 1210 * propagation or type inference with which this [TypeRef] is associated. | 1210 * propagation or type inference with which this [TypeRef] is associated. |
| 1211 * | 1211 * |
| 1212 * Otherwise zero. | 1212 * Otherwise zero. |
| 1213 */ | 1213 */ |
| 1214 void set slot(int _value) { | 1214 void set slot(int _value) { |
| 1215 assert(!_finished); | 1215 assert(!_finished); |
| 1216 assert(_value == null || _value >= 0); | 1216 assert(_value == null || _value >= 0); |
| 1217 _slot = _value; | 1217 _slot = _value; |
| 1218 } | 1218 } |
| 1219 | 1219 |
| 1220 @override | 1220 @override |
| 1221 int get reference => _reference ?? 0; | 1221 int get reference => _reference ??= 0; |
| 1222 | 1222 |
| 1223 /** | 1223 /** |
| 1224 * Index into [UnlinkedUnit.references] for the type being referred to, or | 1224 * Index into [UnlinkedUnit.references] for the type being referred to, or |
| 1225 * zero if this is a reference to a type parameter. | 1225 * zero if this is a reference to a type parameter. |
| 1226 * | 1226 * |
| 1227 * Note that since zero is also a valid index into | 1227 * Note that since zero is also a valid index into |
| 1228 * [UnlinkedUnit.references], we cannot distinguish between references to | 1228 * [UnlinkedUnit.references], we cannot distinguish between references to |
| 1229 * type parameters and references to types by checking [reference] against | 1229 * type parameters and references to types by checking [reference] against |
| 1230 * zero. To distinguish between references to type parameters and references | 1230 * zero. To distinguish between references to type parameters and references |
| 1231 * to types, check whether [paramReference] is zero. | 1231 * to types, check whether [paramReference] is zero. |
| 1232 */ | 1232 */ |
| 1233 void set reference(int _value) { | 1233 void set reference(int _value) { |
| 1234 assert(!_finished); | 1234 assert(!_finished); |
| 1235 assert(_value == null || _value >= 0); | 1235 assert(_value == null || _value >= 0); |
| 1236 _reference = _value; | 1236 _reference = _value; |
| 1237 } | 1237 } |
| 1238 | 1238 |
| 1239 @override | 1239 @override |
| 1240 int get paramReference => _paramReference ?? 0; | 1240 int get paramReference => _paramReference ??= 0; |
| 1241 | 1241 |
| 1242 /** | 1242 /** |
| 1243 * If this is a reference to a type parameter, one-based index into the list | 1243 * If this is a reference to a type parameter, one-based index into the list |
| 1244 * of [UnlinkedTypeParam]s currently in effect. Indexing is done using De | 1244 * of [UnlinkedTypeParam]s currently in effect. Indexing is done using De |
| 1245 * Bruijn index conventions; that is, innermost parameters come first, and | 1245 * Bruijn index conventions; that is, innermost parameters come first, and |
| 1246 * if a class or method has multiple parameters, they are indexed from right | 1246 * if a class or method has multiple parameters, they are indexed from right |
| 1247 * to left. So for instance, if the enclosing declaration is | 1247 * to left. So for instance, if the enclosing declaration is |
| 1248 * | 1248 * |
| 1249 * class C<T,U> { | 1249 * class C<T,U> { |
| 1250 * m<V,W> { | 1250 * m<V,W> { |
| 1251 * ... | 1251 * ... |
| 1252 * } | 1252 * } |
| 1253 * } | 1253 * } |
| 1254 * | 1254 * |
| 1255 * Then [paramReference] values of 1, 2, 3, and 4 represent W, V, U, and T, | 1255 * Then [paramReference] values of 1, 2, 3, and 4 represent W, V, U, and T, |
| 1256 * respectively. | 1256 * respectively. |
| 1257 * | 1257 * |
| 1258 * If the type being referred to is not a type parameter, [paramReference] is | 1258 * If the type being referred to is not a type parameter, [paramReference] is |
| 1259 * zero. | 1259 * zero. |
| 1260 */ | 1260 */ |
| 1261 void set paramReference(int _value) { | 1261 void set paramReference(int _value) { |
| 1262 assert(!_finished); | 1262 assert(!_finished); |
| 1263 assert(_value == null || _value >= 0); | 1263 assert(_value == null || _value >= 0); |
| 1264 _paramReference = _value; | 1264 _paramReference = _value; |
| 1265 } | 1265 } |
| 1266 | 1266 |
| 1267 @override | 1267 @override |
| 1268 List<TypeRef> get typeArguments => _typeArguments ?? const <TypeRef>[]; | 1268 List<TypeRefBuilder> get typeArguments => _typeArguments ??= <TypeRefBuilder>[
]; |
| 1269 | 1269 |
| 1270 /** | 1270 /** |
| 1271 * If this is an instantiation of a generic type, the type arguments used to | 1271 * If this is an instantiation of a generic type, the type arguments used to |
| 1272 * instantiate it. Trailing type arguments of type `dynamic` are omitted. | 1272 * instantiate it. Trailing type arguments of type `dynamic` are omitted. |
| 1273 */ | 1273 */ |
| 1274 void set typeArguments(List<TypeRefBuilder> _value) { | 1274 void set typeArguments(List<TypeRefBuilder> _value) { |
| 1275 assert(!_finished); | 1275 assert(!_finished); |
| 1276 _typeArguments = _value; | 1276 _typeArguments = _value; |
| 1277 } | 1277 } |
| 1278 | 1278 |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1422 TypeRefBuilder _supertype; | 1422 TypeRefBuilder _supertype; |
| 1423 List<TypeRefBuilder> _mixins; | 1423 List<TypeRefBuilder> _mixins; |
| 1424 List<TypeRefBuilder> _interfaces; | 1424 List<TypeRefBuilder> _interfaces; |
| 1425 List<UnlinkedVariableBuilder> _fields; | 1425 List<UnlinkedVariableBuilder> _fields; |
| 1426 List<UnlinkedExecutableBuilder> _executables; | 1426 List<UnlinkedExecutableBuilder> _executables; |
| 1427 bool _isAbstract; | 1427 bool _isAbstract; |
| 1428 bool _isMixinApplication; | 1428 bool _isMixinApplication; |
| 1429 bool _hasNoSupertype; | 1429 bool _hasNoSupertype; |
| 1430 | 1430 |
| 1431 @override | 1431 @override |
| 1432 String get name => _name ?? ''; | 1432 String get name => _name ??= ''; |
| 1433 | 1433 |
| 1434 /** | 1434 /** |
| 1435 * Name of the class. | 1435 * Name of the class. |
| 1436 */ | 1436 */ |
| 1437 void set name(String _value) { | 1437 void set name(String _value) { |
| 1438 assert(!_finished); | 1438 assert(!_finished); |
| 1439 _name = _value; | 1439 _name = _value; |
| 1440 } | 1440 } |
| 1441 | 1441 |
| 1442 @override | 1442 @override |
| 1443 int get nameOffset => _nameOffset ?? 0; | 1443 int get nameOffset => _nameOffset ??= 0; |
| 1444 | 1444 |
| 1445 /** | 1445 /** |
| 1446 * Offset of the class name relative to the beginning of the file. | 1446 * Offset of the class name relative to the beginning of the file. |
| 1447 */ | 1447 */ |
| 1448 void set nameOffset(int _value) { | 1448 void set nameOffset(int _value) { |
| 1449 assert(!_finished); | 1449 assert(!_finished); |
| 1450 assert(_value == null || _value >= 0); | 1450 assert(_value == null || _value >= 0); |
| 1451 _nameOffset = _value; | 1451 _nameOffset = _value; |
| 1452 } | 1452 } |
| 1453 | 1453 |
| 1454 @override | 1454 @override |
| 1455 UnlinkedDocumentationComment get documentationComment => _documentationComment
; | 1455 UnlinkedDocumentationCommentBuilder get documentationComment => _documentation
Comment; |
| 1456 | 1456 |
| 1457 /** | 1457 /** |
| 1458 * Documentation comment for the class, or `null` if there is no | 1458 * Documentation comment for the class, or `null` if there is no |
| 1459 * documentation comment. | 1459 * documentation comment. |
| 1460 */ | 1460 */ |
| 1461 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { | 1461 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { |
| 1462 assert(!_finished); | 1462 assert(!_finished); |
| 1463 _documentationComment = _value; | 1463 _documentationComment = _value; |
| 1464 } | 1464 } |
| 1465 | 1465 |
| 1466 @override | 1466 @override |
| 1467 List<UnlinkedTypeParam> get typeParameters => _typeParameters ?? const <Unlink
edTypeParam>[]; | 1467 List<UnlinkedTypeParamBuilder> get typeParameters => _typeParameters ??= <Unli
nkedTypeParamBuilder>[]; |
| 1468 | 1468 |
| 1469 /** | 1469 /** |
| 1470 * Type parameters of the class, if any. | 1470 * Type parameters of the class, if any. |
| 1471 */ | 1471 */ |
| 1472 void set typeParameters(List<UnlinkedTypeParamBuilder> _value) { | 1472 void set typeParameters(List<UnlinkedTypeParamBuilder> _value) { |
| 1473 assert(!_finished); | 1473 assert(!_finished); |
| 1474 _typeParameters = _value; | 1474 _typeParameters = _value; |
| 1475 } | 1475 } |
| 1476 | 1476 |
| 1477 @override | 1477 @override |
| 1478 TypeRef get supertype => _supertype; | 1478 TypeRefBuilder get supertype => _supertype; |
| 1479 | 1479 |
| 1480 /** | 1480 /** |
| 1481 * Supertype of the class, or `null` if either (a) the class doesn't | 1481 * Supertype of the class, or `null` if either (a) the class doesn't |
| 1482 * explicitly declare a supertype (and hence has supertype `Object`), or (b) | 1482 * explicitly declare a supertype (and hence has supertype `Object`), or (b) |
| 1483 * the class *is* `Object` (and hence has no supertype). | 1483 * the class *is* `Object` (and hence has no supertype). |
| 1484 */ | 1484 */ |
| 1485 void set supertype(TypeRefBuilder _value) { | 1485 void set supertype(TypeRefBuilder _value) { |
| 1486 assert(!_finished); | 1486 assert(!_finished); |
| 1487 _supertype = _value; | 1487 _supertype = _value; |
| 1488 } | 1488 } |
| 1489 | 1489 |
| 1490 @override | 1490 @override |
| 1491 List<TypeRef> get mixins => _mixins ?? const <TypeRef>[]; | 1491 List<TypeRefBuilder> get mixins => _mixins ??= <TypeRefBuilder>[]; |
| 1492 | 1492 |
| 1493 /** | 1493 /** |
| 1494 * Mixins appearing in a `with` clause, if any. | 1494 * Mixins appearing in a `with` clause, if any. |
| 1495 */ | 1495 */ |
| 1496 void set mixins(List<TypeRefBuilder> _value) { | 1496 void set mixins(List<TypeRefBuilder> _value) { |
| 1497 assert(!_finished); | 1497 assert(!_finished); |
| 1498 _mixins = _value; | 1498 _mixins = _value; |
| 1499 } | 1499 } |
| 1500 | 1500 |
| 1501 @override | 1501 @override |
| 1502 List<TypeRef> get interfaces => _interfaces ?? const <TypeRef>[]; | 1502 List<TypeRefBuilder> get interfaces => _interfaces ??= <TypeRefBuilder>[]; |
| 1503 | 1503 |
| 1504 /** | 1504 /** |
| 1505 * Interfaces appearing in an `implements` clause, if any. | 1505 * Interfaces appearing in an `implements` clause, if any. |
| 1506 */ | 1506 */ |
| 1507 void set interfaces(List<TypeRefBuilder> _value) { | 1507 void set interfaces(List<TypeRefBuilder> _value) { |
| 1508 assert(!_finished); | 1508 assert(!_finished); |
| 1509 _interfaces = _value; | 1509 _interfaces = _value; |
| 1510 } | 1510 } |
| 1511 | 1511 |
| 1512 @override | 1512 @override |
| 1513 List<UnlinkedVariable> get fields => _fields ?? const <UnlinkedVariable>[]; | 1513 List<UnlinkedVariableBuilder> get fields => _fields ??= <UnlinkedVariableBuild
er>[]; |
| 1514 | 1514 |
| 1515 /** | 1515 /** |
| 1516 * Field declarations contained in the class. | 1516 * Field declarations contained in the class. |
| 1517 */ | 1517 */ |
| 1518 void set fields(List<UnlinkedVariableBuilder> _value) { | 1518 void set fields(List<UnlinkedVariableBuilder> _value) { |
| 1519 assert(!_finished); | 1519 assert(!_finished); |
| 1520 _fields = _value; | 1520 _fields = _value; |
| 1521 } | 1521 } |
| 1522 | 1522 |
| 1523 @override | 1523 @override |
| 1524 List<UnlinkedExecutable> get executables => _executables ?? const <UnlinkedExe
cutable>[]; | 1524 List<UnlinkedExecutableBuilder> get executables => _executables ??= <UnlinkedE
xecutableBuilder>[]; |
| 1525 | 1525 |
| 1526 /** | 1526 /** |
| 1527 * Executable objects (methods, getters, and setters) contained in the class. | 1527 * Executable objects (methods, getters, and setters) contained in the class. |
| 1528 */ | 1528 */ |
| 1529 void set executables(List<UnlinkedExecutableBuilder> _value) { | 1529 void set executables(List<UnlinkedExecutableBuilder> _value) { |
| 1530 assert(!_finished); | 1530 assert(!_finished); |
| 1531 _executables = _value; | 1531 _executables = _value; |
| 1532 } | 1532 } |
| 1533 | 1533 |
| 1534 @override | 1534 @override |
| 1535 bool get isAbstract => _isAbstract ?? false; | 1535 bool get isAbstract => _isAbstract ??= false; |
| 1536 | 1536 |
| 1537 /** | 1537 /** |
| 1538 * Indicates whether the class is declared with the `abstract` keyword. | 1538 * Indicates whether the class is declared with the `abstract` keyword. |
| 1539 */ | 1539 */ |
| 1540 void set isAbstract(bool _value) { | 1540 void set isAbstract(bool _value) { |
| 1541 assert(!_finished); | 1541 assert(!_finished); |
| 1542 _isAbstract = _value; | 1542 _isAbstract = _value; |
| 1543 } | 1543 } |
| 1544 | 1544 |
| 1545 @override | 1545 @override |
| 1546 bool get isMixinApplication => _isMixinApplication ?? false; | 1546 bool get isMixinApplication => _isMixinApplication ??= false; |
| 1547 | 1547 |
| 1548 /** | 1548 /** |
| 1549 * Indicates whether the class is declared using mixin application syntax. | 1549 * Indicates whether the class is declared using mixin application syntax. |
| 1550 */ | 1550 */ |
| 1551 void set isMixinApplication(bool _value) { | 1551 void set isMixinApplication(bool _value) { |
| 1552 assert(!_finished); | 1552 assert(!_finished); |
| 1553 _isMixinApplication = _value; | 1553 _isMixinApplication = _value; |
| 1554 } | 1554 } |
| 1555 | 1555 |
| 1556 @override | 1556 @override |
| 1557 bool get hasNoSupertype => _hasNoSupertype ?? false; | 1557 bool get hasNoSupertype => _hasNoSupertype ??= false; |
| 1558 | 1558 |
| 1559 /** | 1559 /** |
| 1560 * Indicates whether this class is the core "Object" class (and hence has no | 1560 * Indicates whether this class is the core "Object" class (and hence has no |
| 1561 * supertype) | 1561 * supertype) |
| 1562 */ | 1562 */ |
| 1563 void set hasNoSupertype(bool _value) { | 1563 void set hasNoSupertype(bool _value) { |
| 1564 assert(!_finished); | 1564 assert(!_finished); |
| 1565 _hasNoSupertype = _value; | 1565 _hasNoSupertype = _value; |
| 1566 } | 1566 } |
| 1567 | 1567 |
| (...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1841 }; | 1841 }; |
| 1842 } | 1842 } |
| 1843 | 1843 |
| 1844 class UnlinkedCombinatorBuilder extends Object with _UnlinkedCombinatorMixin imp
lements UnlinkedCombinator { | 1844 class UnlinkedCombinatorBuilder extends Object with _UnlinkedCombinatorMixin imp
lements UnlinkedCombinator { |
| 1845 bool _finished = false; | 1845 bool _finished = false; |
| 1846 | 1846 |
| 1847 List<String> _shows; | 1847 List<String> _shows; |
| 1848 List<String> _hides; | 1848 List<String> _hides; |
| 1849 | 1849 |
| 1850 @override | 1850 @override |
| 1851 List<String> get shows => _shows ?? const <String>[]; | 1851 List<String> get shows => _shows ??= <String>[]; |
| 1852 | 1852 |
| 1853 /** | 1853 /** |
| 1854 * List of names which are shown. Empty if this is a `hide` combinator. | 1854 * List of names which are shown. Empty if this is a `hide` combinator. |
| 1855 */ | 1855 */ |
| 1856 void set shows(List<String> _value) { | 1856 void set shows(List<String> _value) { |
| 1857 assert(!_finished); | 1857 assert(!_finished); |
| 1858 _shows = _value; | 1858 _shows = _value; |
| 1859 } | 1859 } |
| 1860 | 1860 |
| 1861 @override | 1861 @override |
| 1862 List<String> get hides => _hides ?? const <String>[]; | 1862 List<String> get hides => _hides ??= <String>[]; |
| 1863 | 1863 |
| 1864 /** | 1864 /** |
| 1865 * List of names which are hidden. Empty if this is a `show` combinator. | 1865 * List of names which are hidden. Empty if this is a `show` combinator. |
| 1866 */ | 1866 */ |
| 1867 void set hides(List<String> _value) { | 1867 void set hides(List<String> _value) { |
| 1868 assert(!_finished); | 1868 assert(!_finished); |
| 1869 _hides = _value; | 1869 _hides = _value; |
| 1870 } | 1870 } |
| 1871 | 1871 |
| 1872 UnlinkedCombinatorBuilder({List<String> shows, List<String> hides}) | 1872 UnlinkedCombinatorBuilder({List<String> shows, List<String> hides}) |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1951 class UnlinkedConstBuilder extends Object with _UnlinkedConstMixin implements Un
linkedConst { | 1951 class UnlinkedConstBuilder extends Object with _UnlinkedConstMixin implements Un
linkedConst { |
| 1952 bool _finished = false; | 1952 bool _finished = false; |
| 1953 | 1953 |
| 1954 List<UnlinkedConstOperation> _operations; | 1954 List<UnlinkedConstOperation> _operations; |
| 1955 List<int> _ints; | 1955 List<int> _ints; |
| 1956 List<double> _doubles; | 1956 List<double> _doubles; |
| 1957 List<String> _strings; | 1957 List<String> _strings; |
| 1958 List<TypeRefBuilder> _references; | 1958 List<TypeRefBuilder> _references; |
| 1959 | 1959 |
| 1960 @override | 1960 @override |
| 1961 List<UnlinkedConstOperation> get operations => _operations ?? const <UnlinkedC
onstOperation>[]; | 1961 List<UnlinkedConstOperation> get operations => _operations ??= <UnlinkedConstO
peration>[]; |
| 1962 | 1962 |
| 1963 /** | 1963 /** |
| 1964 * Sequence of operations to execute (starting with an empty stack) to form | 1964 * Sequence of operations to execute (starting with an empty stack) to form |
| 1965 * the constant value. | 1965 * the constant value. |
| 1966 */ | 1966 */ |
| 1967 void set operations(List<UnlinkedConstOperation> _value) { | 1967 void set operations(List<UnlinkedConstOperation> _value) { |
| 1968 assert(!_finished); | 1968 assert(!_finished); |
| 1969 _operations = _value; | 1969 _operations = _value; |
| 1970 } | 1970 } |
| 1971 | 1971 |
| 1972 @override | 1972 @override |
| 1973 List<int> get ints => _ints ?? const <int>[]; | 1973 List<int> get ints => _ints ??= <int>[]; |
| 1974 | 1974 |
| 1975 /** | 1975 /** |
| 1976 * Sequence of unsigned 32-bit integers consumed by the operations | 1976 * Sequence of unsigned 32-bit integers consumed by the operations |
| 1977 * `pushArgument`, `pushInt`, `shiftOr`, `concatenate`, `invokeConstructor`, | 1977 * `pushArgument`, `pushInt`, `shiftOr`, `concatenate`, `invokeConstructor`, |
| 1978 * `makeList`, and `makeMap`. | 1978 * `makeList`, and `makeMap`. |
| 1979 */ | 1979 */ |
| 1980 void set ints(List<int> _value) { | 1980 void set ints(List<int> _value) { |
| 1981 assert(!_finished); | 1981 assert(!_finished); |
| 1982 assert(_value == null || _value.every((e) => e >= 0)); | 1982 assert(_value == null || _value.every((e) => e >= 0)); |
| 1983 _ints = _value; | 1983 _ints = _value; |
| 1984 } | 1984 } |
| 1985 | 1985 |
| 1986 @override | 1986 @override |
| 1987 List<double> get doubles => _doubles ?? const <double>[]; | 1987 List<double> get doubles => _doubles ??= <double>[]; |
| 1988 | 1988 |
| 1989 /** | 1989 /** |
| 1990 * Sequence of 64-bit doubles consumed by the operation `pushDouble`. | 1990 * Sequence of 64-bit doubles consumed by the operation `pushDouble`. |
| 1991 */ | 1991 */ |
| 1992 void set doubles(List<double> _value) { | 1992 void set doubles(List<double> _value) { |
| 1993 assert(!_finished); | 1993 assert(!_finished); |
| 1994 _doubles = _value; | 1994 _doubles = _value; |
| 1995 } | 1995 } |
| 1996 | 1996 |
| 1997 @override | 1997 @override |
| 1998 List<String> get strings => _strings ?? const <String>[]; | 1998 List<String> get strings => _strings ??= <String>[]; |
| 1999 | 1999 |
| 2000 /** | 2000 /** |
| 2001 * Sequence of strings consumed by the operations `pushString` and | 2001 * Sequence of strings consumed by the operations `pushString` and |
| 2002 * `invokeConstructor`. | 2002 * `invokeConstructor`. |
| 2003 */ | 2003 */ |
| 2004 void set strings(List<String> _value) { | 2004 void set strings(List<String> _value) { |
| 2005 assert(!_finished); | 2005 assert(!_finished); |
| 2006 _strings = _value; | 2006 _strings = _value; |
| 2007 } | 2007 } |
| 2008 | 2008 |
| 2009 @override | 2009 @override |
| 2010 List<TypeRef> get references => _references ?? const <TypeRef>[]; | 2010 List<TypeRefBuilder> get references => _references ??= <TypeRefBuilder>[]; |
| 2011 | 2011 |
| 2012 /** | 2012 /** |
| 2013 * Sequence of language constructs consumed by the operations | 2013 * Sequence of language constructs consumed by the operations |
| 2014 * `pushReference`, `invokeConstructor`, `makeList`, and `makeMap`. Note | 2014 * `pushReference`, `invokeConstructor`, `makeList`, and `makeMap`. Note |
| 2015 * that in the case of `pushReference` (and sometimes `invokeConstructor` the | 2015 * that in the case of `pushReference` (and sometimes `invokeConstructor` the |
| 2016 * actual entity being referred to may be something other than a type. | 2016 * actual entity being referred to may be something other than a type. |
| 2017 */ | 2017 */ |
| 2018 void set references(List<TypeRefBuilder> _value) { | 2018 void set references(List<TypeRefBuilder> _value) { |
| 2019 assert(!_finished); | 2019 assert(!_finished); |
| 2020 _references = _value; | 2020 _references = _value; |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2176 } | 2176 } |
| 2177 | 2177 |
| 2178 class UnlinkedDocumentationCommentBuilder extends Object with _UnlinkedDocumenta
tionCommentMixin implements UnlinkedDocumentationComment { | 2178 class UnlinkedDocumentationCommentBuilder extends Object with _UnlinkedDocumenta
tionCommentMixin implements UnlinkedDocumentationComment { |
| 2179 bool _finished = false; | 2179 bool _finished = false; |
| 2180 | 2180 |
| 2181 String _text; | 2181 String _text; |
| 2182 int _offset; | 2182 int _offset; |
| 2183 int _length; | 2183 int _length; |
| 2184 | 2184 |
| 2185 @override | 2185 @override |
| 2186 String get text => _text ?? ''; | 2186 String get text => _text ??= ''; |
| 2187 | 2187 |
| 2188 /** | 2188 /** |
| 2189 * Text of the documentation comment, with '\r\n' replaced by '\n'. | 2189 * Text of the documentation comment, with '\r\n' replaced by '\n'. |
| 2190 * | 2190 * |
| 2191 * References appearing within the doc comment in square brackets are not | 2191 * References appearing within the doc comment in square brackets are not |
| 2192 * specially encoded. | 2192 * specially encoded. |
| 2193 */ | 2193 */ |
| 2194 void set text(String _value) { | 2194 void set text(String _value) { |
| 2195 assert(!_finished); | 2195 assert(!_finished); |
| 2196 _text = _value; | 2196 _text = _value; |
| 2197 } | 2197 } |
| 2198 | 2198 |
| 2199 @override | 2199 @override |
| 2200 int get offset => _offset ?? 0; | 2200 int get offset => _offset ??= 0; |
| 2201 | 2201 |
| 2202 /** | 2202 /** |
| 2203 * Offset of the beginning of the documentation comment relative to the | 2203 * Offset of the beginning of the documentation comment relative to the |
| 2204 * beginning of the file. | 2204 * beginning of the file. |
| 2205 */ | 2205 */ |
| 2206 void set offset(int _value) { | 2206 void set offset(int _value) { |
| 2207 assert(!_finished); | 2207 assert(!_finished); |
| 2208 assert(_value == null || _value >= 0); | 2208 assert(_value == null || _value >= 0); |
| 2209 _offset = _value; | 2209 _offset = _value; |
| 2210 } | 2210 } |
| 2211 | 2211 |
| 2212 @override | 2212 @override |
| 2213 int get length => _length ?? 0; | 2213 int get length => _length ??= 0; |
| 2214 | 2214 |
| 2215 /** | 2215 /** |
| 2216 * Length of the documentation comment (prior to replacing '\r\n' with '\n'). | 2216 * Length of the documentation comment (prior to replacing '\r\n' with '\n'). |
| 2217 */ | 2217 */ |
| 2218 void set length(int _value) { | 2218 void set length(int _value) { |
| 2219 assert(!_finished); | 2219 assert(!_finished); |
| 2220 assert(_value == null || _value >= 0); | 2220 assert(_value == null || _value >= 0); |
| 2221 _length = _value; | 2221 _length = _value; |
| 2222 } | 2222 } |
| 2223 | 2223 |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2318 | 2318 |
| 2319 class UnlinkedEnumBuilder extends Object with _UnlinkedEnumMixin implements Unli
nkedEnum { | 2319 class UnlinkedEnumBuilder extends Object with _UnlinkedEnumMixin implements Unli
nkedEnum { |
| 2320 bool _finished = false; | 2320 bool _finished = false; |
| 2321 | 2321 |
| 2322 String _name; | 2322 String _name; |
| 2323 int _nameOffset; | 2323 int _nameOffset; |
| 2324 UnlinkedDocumentationCommentBuilder _documentationComment; | 2324 UnlinkedDocumentationCommentBuilder _documentationComment; |
| 2325 List<UnlinkedEnumValueBuilder> _values; | 2325 List<UnlinkedEnumValueBuilder> _values; |
| 2326 | 2326 |
| 2327 @override | 2327 @override |
| 2328 String get name => _name ?? ''; | 2328 String get name => _name ??= ''; |
| 2329 | 2329 |
| 2330 /** | 2330 /** |
| 2331 * Name of the enum type. | 2331 * Name of the enum type. |
| 2332 */ | 2332 */ |
| 2333 void set name(String _value) { | 2333 void set name(String _value) { |
| 2334 assert(!_finished); | 2334 assert(!_finished); |
| 2335 _name = _value; | 2335 _name = _value; |
| 2336 } | 2336 } |
| 2337 | 2337 |
| 2338 @override | 2338 @override |
| 2339 int get nameOffset => _nameOffset ?? 0; | 2339 int get nameOffset => _nameOffset ??= 0; |
| 2340 | 2340 |
| 2341 /** | 2341 /** |
| 2342 * Offset of the enum name relative to the beginning of the file. | 2342 * Offset of the enum name relative to the beginning of the file. |
| 2343 */ | 2343 */ |
| 2344 void set nameOffset(int _value) { | 2344 void set nameOffset(int _value) { |
| 2345 assert(!_finished); | 2345 assert(!_finished); |
| 2346 assert(_value == null || _value >= 0); | 2346 assert(_value == null || _value >= 0); |
| 2347 _nameOffset = _value; | 2347 _nameOffset = _value; |
| 2348 } | 2348 } |
| 2349 | 2349 |
| 2350 @override | 2350 @override |
| 2351 UnlinkedDocumentationComment get documentationComment => _documentationComment
; | 2351 UnlinkedDocumentationCommentBuilder get documentationComment => _documentation
Comment; |
| 2352 | 2352 |
| 2353 /** | 2353 /** |
| 2354 * Documentation comment for the enum, or `null` if there is no documentation | 2354 * Documentation comment for the enum, or `null` if there is no documentation |
| 2355 * comment. | 2355 * comment. |
| 2356 */ | 2356 */ |
| 2357 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { | 2357 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { |
| 2358 assert(!_finished); | 2358 assert(!_finished); |
| 2359 _documentationComment = _value; | 2359 _documentationComment = _value; |
| 2360 } | 2360 } |
| 2361 | 2361 |
| 2362 @override | 2362 @override |
| 2363 List<UnlinkedEnumValue> get values => _values ?? const <UnlinkedEnumValue>[]; | 2363 List<UnlinkedEnumValueBuilder> get values => _values ??= <UnlinkedEnumValueBui
lder>[]; |
| 2364 | 2364 |
| 2365 /** | 2365 /** |
| 2366 * Values listed in the enum declaration, in declaration order. | 2366 * Values listed in the enum declaration, in declaration order. |
| 2367 */ | 2367 */ |
| 2368 void set values(List<UnlinkedEnumValueBuilder> _value) { | 2368 void set values(List<UnlinkedEnumValueBuilder> _value) { |
| 2369 assert(!_finished); | 2369 assert(!_finished); |
| 2370 _values = _value; | 2370 _values = _value; |
| 2371 } | 2371 } |
| 2372 | 2372 |
| 2373 UnlinkedEnumBuilder({String name, int nameOffset, UnlinkedDocumentationComment
Builder documentationComment, List<UnlinkedEnumValueBuilder> values}) | 2373 UnlinkedEnumBuilder({String name, int nameOffset, UnlinkedDocumentationComment
Builder documentationComment, List<UnlinkedEnumValueBuilder> values}) |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2488 } | 2488 } |
| 2489 | 2489 |
| 2490 class UnlinkedEnumValueBuilder extends Object with _UnlinkedEnumValueMixin imple
ments UnlinkedEnumValue { | 2490 class UnlinkedEnumValueBuilder extends Object with _UnlinkedEnumValueMixin imple
ments UnlinkedEnumValue { |
| 2491 bool _finished = false; | 2491 bool _finished = false; |
| 2492 | 2492 |
| 2493 String _name; | 2493 String _name; |
| 2494 int _nameOffset; | 2494 int _nameOffset; |
| 2495 UnlinkedDocumentationCommentBuilder _documentationComment; | 2495 UnlinkedDocumentationCommentBuilder _documentationComment; |
| 2496 | 2496 |
| 2497 @override | 2497 @override |
| 2498 String get name => _name ?? ''; | 2498 String get name => _name ??= ''; |
| 2499 | 2499 |
| 2500 /** | 2500 /** |
| 2501 * Name of the enumerated value. | 2501 * Name of the enumerated value. |
| 2502 */ | 2502 */ |
| 2503 void set name(String _value) { | 2503 void set name(String _value) { |
| 2504 assert(!_finished); | 2504 assert(!_finished); |
| 2505 _name = _value; | 2505 _name = _value; |
| 2506 } | 2506 } |
| 2507 | 2507 |
| 2508 @override | 2508 @override |
| 2509 int get nameOffset => _nameOffset ?? 0; | 2509 int get nameOffset => _nameOffset ??= 0; |
| 2510 | 2510 |
| 2511 /** | 2511 /** |
| 2512 * Offset of the enum value name relative to the beginning of the file. | 2512 * Offset of the enum value name relative to the beginning of the file. |
| 2513 */ | 2513 */ |
| 2514 void set nameOffset(int _value) { | 2514 void set nameOffset(int _value) { |
| 2515 assert(!_finished); | 2515 assert(!_finished); |
| 2516 assert(_value == null || _value >= 0); | 2516 assert(_value == null || _value >= 0); |
| 2517 _nameOffset = _value; | 2517 _nameOffset = _value; |
| 2518 } | 2518 } |
| 2519 | 2519 |
| 2520 @override | 2520 @override |
| 2521 UnlinkedDocumentationComment get documentationComment => _documentationComment
; | 2521 UnlinkedDocumentationCommentBuilder get documentationComment => _documentation
Comment; |
| 2522 | 2522 |
| 2523 /** | 2523 /** |
| 2524 * Documentation comment for the enum value, or `null` if there is no | 2524 * Documentation comment for the enum value, or `null` if there is no |
| 2525 * documentation comment. | 2525 * documentation comment. |
| 2526 */ | 2526 */ |
| 2527 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { | 2527 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { |
| 2528 assert(!_finished); | 2528 assert(!_finished); |
| 2529 _documentationComment = _value; | 2529 _documentationComment = _value; |
| 2530 } | 2530 } |
| 2531 | 2531 |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2637 List<UnlinkedParamBuilder> _parameters; | 2637 List<UnlinkedParamBuilder> _parameters; |
| 2638 UnlinkedExecutableKind _kind; | 2638 UnlinkedExecutableKind _kind; |
| 2639 bool _isAbstract; | 2639 bool _isAbstract; |
| 2640 bool _isStatic; | 2640 bool _isStatic; |
| 2641 bool _isConst; | 2641 bool _isConst; |
| 2642 bool _isFactory; | 2642 bool _isFactory; |
| 2643 bool _hasImplicitReturnType; | 2643 bool _hasImplicitReturnType; |
| 2644 bool _isExternal; | 2644 bool _isExternal; |
| 2645 | 2645 |
| 2646 @override | 2646 @override |
| 2647 String get name => _name ?? ''; | 2647 String get name => _name ??= ''; |
| 2648 | 2648 |
| 2649 /** | 2649 /** |
| 2650 * Name of the executable. For setters, this includes the trailing "=". For | 2650 * Name of the executable. For setters, this includes the trailing "=". For |
| 2651 * named constructors, this excludes the class name and excludes the ".". | 2651 * named constructors, this excludes the class name and excludes the ".". |
| 2652 * For unnamed constructors, this is the empty string. | 2652 * For unnamed constructors, this is the empty string. |
| 2653 */ | 2653 */ |
| 2654 void set name(String _value) { | 2654 void set name(String _value) { |
| 2655 assert(!_finished); | 2655 assert(!_finished); |
| 2656 _name = _value; | 2656 _name = _value; |
| 2657 } | 2657 } |
| 2658 | 2658 |
| 2659 @override | 2659 @override |
| 2660 int get nameOffset => _nameOffset ?? 0; | 2660 int get nameOffset => _nameOffset ??= 0; |
| 2661 | 2661 |
| 2662 /** | 2662 /** |
| 2663 * Offset of the executable name relative to the beginning of the file. For | 2663 * Offset of the executable name relative to the beginning of the file. For |
| 2664 * named constructors, this excludes the class name and excludes the ".". | 2664 * named constructors, this excludes the class name and excludes the ".". |
| 2665 * For unnamed constructors, this is the offset of the class name (i.e. the | 2665 * For unnamed constructors, this is the offset of the class name (i.e. the |
| 2666 * offset of the second "C" in "class C { C(); }"). | 2666 * offset of the second "C" in "class C { C(); }"). |
| 2667 */ | 2667 */ |
| 2668 void set nameOffset(int _value) { | 2668 void set nameOffset(int _value) { |
| 2669 assert(!_finished); | 2669 assert(!_finished); |
| 2670 assert(_value == null || _value >= 0); | 2670 assert(_value == null || _value >= 0); |
| 2671 _nameOffset = _value; | 2671 _nameOffset = _value; |
| 2672 } | 2672 } |
| 2673 | 2673 |
| 2674 @override | 2674 @override |
| 2675 UnlinkedDocumentationComment get documentationComment => _documentationComment
; | 2675 UnlinkedDocumentationCommentBuilder get documentationComment => _documentation
Comment; |
| 2676 | 2676 |
| 2677 /** | 2677 /** |
| 2678 * Documentation comment for the executable, or `null` if there is no | 2678 * Documentation comment for the executable, or `null` if there is no |
| 2679 * documentation comment. | 2679 * documentation comment. |
| 2680 */ | 2680 */ |
| 2681 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { | 2681 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { |
| 2682 assert(!_finished); | 2682 assert(!_finished); |
| 2683 _documentationComment = _value; | 2683 _documentationComment = _value; |
| 2684 } | 2684 } |
| 2685 | 2685 |
| 2686 @override | 2686 @override |
| 2687 List<UnlinkedTypeParam> get typeParameters => _typeParameters ?? const <Unlink
edTypeParam>[]; | 2687 List<UnlinkedTypeParamBuilder> get typeParameters => _typeParameters ??= <Unli
nkedTypeParamBuilder>[]; |
| 2688 | 2688 |
| 2689 /** | 2689 /** |
| 2690 * Type parameters of the executable, if any. Empty if support for generic | 2690 * Type parameters of the executable, if any. Empty if support for generic |
| 2691 * method syntax is disabled. | 2691 * method syntax is disabled. |
| 2692 */ | 2692 */ |
| 2693 void set typeParameters(List<UnlinkedTypeParamBuilder> _value) { | 2693 void set typeParameters(List<UnlinkedTypeParamBuilder> _value) { |
| 2694 assert(!_finished); | 2694 assert(!_finished); |
| 2695 _typeParameters = _value; | 2695 _typeParameters = _value; |
| 2696 } | 2696 } |
| 2697 | 2697 |
| 2698 @override | 2698 @override |
| 2699 TypeRef get returnType => _returnType; | 2699 TypeRefBuilder get returnType => _returnType; |
| 2700 | 2700 |
| 2701 /** | 2701 /** |
| 2702 * Declared return type of the executable. Absent if the return type is | 2702 * Declared return type of the executable. Absent if the return type is |
| 2703 * `void` or the executable is a constructor. Note that when strong mode is | 2703 * `void` or the executable is a constructor. Note that when strong mode is |
| 2704 * enabled, the actual return type may be different due to type inference. | 2704 * enabled, the actual return type may be different due to type inference. |
| 2705 */ | 2705 */ |
| 2706 void set returnType(TypeRefBuilder _value) { | 2706 void set returnType(TypeRefBuilder _value) { |
| 2707 assert(!_finished); | 2707 assert(!_finished); |
| 2708 _returnType = _value; | 2708 _returnType = _value; |
| 2709 } | 2709 } |
| 2710 | 2710 |
| 2711 @override | 2711 @override |
| 2712 List<UnlinkedParam> get parameters => _parameters ?? const <UnlinkedParam>[]; | 2712 List<UnlinkedParamBuilder> get parameters => _parameters ??= <UnlinkedParamBui
lder>[]; |
| 2713 | 2713 |
| 2714 /** | 2714 /** |
| 2715 * Parameters of the executable, if any. Note that getters have no | 2715 * Parameters of the executable, if any. Note that getters have no |
| 2716 * parameters (hence this will be the empty list), and setters have a single | 2716 * parameters (hence this will be the empty list), and setters have a single |
| 2717 * parameter. | 2717 * parameter. |
| 2718 */ | 2718 */ |
| 2719 void set parameters(List<UnlinkedParamBuilder> _value) { | 2719 void set parameters(List<UnlinkedParamBuilder> _value) { |
| 2720 assert(!_finished); | 2720 assert(!_finished); |
| 2721 _parameters = _value; | 2721 _parameters = _value; |
| 2722 } | 2722 } |
| 2723 | 2723 |
| 2724 @override | 2724 @override |
| 2725 UnlinkedExecutableKind get kind => _kind ?? UnlinkedExecutableKind.functionOrM
ethod; | 2725 UnlinkedExecutableKind get kind => _kind ??= UnlinkedExecutableKind.functionOr
Method; |
| 2726 | 2726 |
| 2727 /** | 2727 /** |
| 2728 * The kind of the executable (function/method, getter, setter, or | 2728 * The kind of the executable (function/method, getter, setter, or |
| 2729 * constructor). | 2729 * constructor). |
| 2730 */ | 2730 */ |
| 2731 void set kind(UnlinkedExecutableKind _value) { | 2731 void set kind(UnlinkedExecutableKind _value) { |
| 2732 assert(!_finished); | 2732 assert(!_finished); |
| 2733 _kind = _value; | 2733 _kind = _value; |
| 2734 } | 2734 } |
| 2735 | 2735 |
| 2736 @override | 2736 @override |
| 2737 bool get isAbstract => _isAbstract ?? false; | 2737 bool get isAbstract => _isAbstract ??= false; |
| 2738 | 2738 |
| 2739 /** | 2739 /** |
| 2740 * Indicates whether the executable is declared using the `abstract` keyword. | 2740 * Indicates whether the executable is declared using the `abstract` keyword. |
| 2741 */ | 2741 */ |
| 2742 void set isAbstract(bool _value) { | 2742 void set isAbstract(bool _value) { |
| 2743 assert(!_finished); | 2743 assert(!_finished); |
| 2744 _isAbstract = _value; | 2744 _isAbstract = _value; |
| 2745 } | 2745 } |
| 2746 | 2746 |
| 2747 @override | 2747 @override |
| 2748 bool get isStatic => _isStatic ?? false; | 2748 bool get isStatic => _isStatic ??= false; |
| 2749 | 2749 |
| 2750 /** | 2750 /** |
| 2751 * Indicates whether the executable is declared using the `static` keyword. | 2751 * Indicates whether the executable is declared using the `static` keyword. |
| 2752 * | 2752 * |
| 2753 * Note that for top level executables, this flag is false, since they are | 2753 * Note that for top level executables, this flag is false, since they are |
| 2754 * not declared using the `static` keyword (even though they are considered | 2754 * not declared using the `static` keyword (even though they are considered |
| 2755 * static for semantic purposes). | 2755 * static for semantic purposes). |
| 2756 */ | 2756 */ |
| 2757 void set isStatic(bool _value) { | 2757 void set isStatic(bool _value) { |
| 2758 assert(!_finished); | 2758 assert(!_finished); |
| 2759 _isStatic = _value; | 2759 _isStatic = _value; |
| 2760 } | 2760 } |
| 2761 | 2761 |
| 2762 @override | 2762 @override |
| 2763 bool get isConst => _isConst ?? false; | 2763 bool get isConst => _isConst ??= false; |
| 2764 | 2764 |
| 2765 /** | 2765 /** |
| 2766 * Indicates whether the executable is declared using the `const` keyword. | 2766 * Indicates whether the executable is declared using the `const` keyword. |
| 2767 */ | 2767 */ |
| 2768 void set isConst(bool _value) { | 2768 void set isConst(bool _value) { |
| 2769 assert(!_finished); | 2769 assert(!_finished); |
| 2770 _isConst = _value; | 2770 _isConst = _value; |
| 2771 } | 2771 } |
| 2772 | 2772 |
| 2773 @override | 2773 @override |
| 2774 bool get isFactory => _isFactory ?? false; | 2774 bool get isFactory => _isFactory ??= false; |
| 2775 | 2775 |
| 2776 /** | 2776 /** |
| 2777 * Indicates whether the executable is declared using the `factory` keyword. | 2777 * Indicates whether the executable is declared using the `factory` keyword. |
| 2778 */ | 2778 */ |
| 2779 void set isFactory(bool _value) { | 2779 void set isFactory(bool _value) { |
| 2780 assert(!_finished); | 2780 assert(!_finished); |
| 2781 _isFactory = _value; | 2781 _isFactory = _value; |
| 2782 } | 2782 } |
| 2783 | 2783 |
| 2784 @override | 2784 @override |
| 2785 bool get hasImplicitReturnType => _hasImplicitReturnType ?? false; | 2785 bool get hasImplicitReturnType => _hasImplicitReturnType ??= false; |
| 2786 | 2786 |
| 2787 /** | 2787 /** |
| 2788 * Indicates whether the executable lacks an explicit return type | 2788 * Indicates whether the executable lacks an explicit return type |
| 2789 * declaration. False for constructors and setters. | 2789 * declaration. False for constructors and setters. |
| 2790 */ | 2790 */ |
| 2791 void set hasImplicitReturnType(bool _value) { | 2791 void set hasImplicitReturnType(bool _value) { |
| 2792 assert(!_finished); | 2792 assert(!_finished); |
| 2793 _hasImplicitReturnType = _value; | 2793 _hasImplicitReturnType = _value; |
| 2794 } | 2794 } |
| 2795 | 2795 |
| 2796 @override | 2796 @override |
| 2797 bool get isExternal => _isExternal ?? false; | 2797 bool get isExternal => _isExternal ??= false; |
| 2798 | 2798 |
| 2799 /** | 2799 /** |
| 2800 * Indicates whether the executable is declared using the `external` keyword. | 2800 * Indicates whether the executable is declared using the `external` keyword. |
| 2801 */ | 2801 */ |
| 2802 void set isExternal(bool _value) { | 2802 void set isExternal(bool _value) { |
| 2803 assert(!_finished); | 2803 assert(!_finished); |
| 2804 _isExternal = _value; | 2804 _isExternal = _value; |
| 2805 } | 2805 } |
| 2806 | 2806 |
| 2807 UnlinkedExecutableBuilder({String name, int nameOffset, UnlinkedDocumentationC
ommentBuilder documentationComment, List<UnlinkedTypeParamBuilder> typeParameter
s, TypeRefBuilder returnType, List<UnlinkedParamBuilder> parameters, UnlinkedExe
cutableKind kind, bool isAbstract, bool isStatic, bool isConst, bool isFactory,
bool hasImplicitReturnType, bool isExternal}) | 2807 UnlinkedExecutableBuilder({String name, int nameOffset, UnlinkedDocumentationC
ommentBuilder documentationComment, List<UnlinkedTypeParamBuilder> typeParameter
s, TypeRefBuilder returnType, List<UnlinkedParamBuilder> parameters, UnlinkedExe
cutableKind kind, bool isAbstract, bool isStatic, bool isConst, bool isFactory,
bool hasImplicitReturnType, bool isExternal}) |
| (...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3100 } | 3100 } |
| 3101 | 3101 |
| 3102 class UnlinkedExportNonPublicBuilder extends Object with _UnlinkedExportNonPubli
cMixin implements UnlinkedExportNonPublic { | 3102 class UnlinkedExportNonPublicBuilder extends Object with _UnlinkedExportNonPubli
cMixin implements UnlinkedExportNonPublic { |
| 3103 bool _finished = false; | 3103 bool _finished = false; |
| 3104 | 3104 |
| 3105 int _offset; | 3105 int _offset; |
| 3106 int _uriOffset; | 3106 int _uriOffset; |
| 3107 int _uriEnd; | 3107 int _uriEnd; |
| 3108 | 3108 |
| 3109 @override | 3109 @override |
| 3110 int get offset => _offset ?? 0; | 3110 int get offset => _offset ??= 0; |
| 3111 | 3111 |
| 3112 /** | 3112 /** |
| 3113 * Offset of the "export" keyword. | 3113 * Offset of the "export" keyword. |
| 3114 */ | 3114 */ |
| 3115 void set offset(int _value) { | 3115 void set offset(int _value) { |
| 3116 assert(!_finished); | 3116 assert(!_finished); |
| 3117 assert(_value == null || _value >= 0); | 3117 assert(_value == null || _value >= 0); |
| 3118 _offset = _value; | 3118 _offset = _value; |
| 3119 } | 3119 } |
| 3120 | 3120 |
| 3121 @override | 3121 @override |
| 3122 int get uriOffset => _uriOffset ?? 0; | 3122 int get uriOffset => _uriOffset ??= 0; |
| 3123 | 3123 |
| 3124 /** | 3124 /** |
| 3125 * Offset of the URI string (including quotes) relative to the beginning of | 3125 * Offset of the URI string (including quotes) relative to the beginning of |
| 3126 * the file. | 3126 * the file. |
| 3127 */ | 3127 */ |
| 3128 void set uriOffset(int _value) { | 3128 void set uriOffset(int _value) { |
| 3129 assert(!_finished); | 3129 assert(!_finished); |
| 3130 assert(_value == null || _value >= 0); | 3130 assert(_value == null || _value >= 0); |
| 3131 _uriOffset = _value; | 3131 _uriOffset = _value; |
| 3132 } | 3132 } |
| 3133 | 3133 |
| 3134 @override | 3134 @override |
| 3135 int get uriEnd => _uriEnd ?? 0; | 3135 int get uriEnd => _uriEnd ??= 0; |
| 3136 | 3136 |
| 3137 /** | 3137 /** |
| 3138 * End of the URI string (including quotes) relative to the beginning of the | 3138 * End of the URI string (including quotes) relative to the beginning of the |
| 3139 * file. | 3139 * file. |
| 3140 */ | 3140 */ |
| 3141 void set uriEnd(int _value) { | 3141 void set uriEnd(int _value) { |
| 3142 assert(!_finished); | 3142 assert(!_finished); |
| 3143 assert(_value == null || _value >= 0); | 3143 assert(_value == null || _value >= 0); |
| 3144 _uriEnd = _value; | 3144 _uriEnd = _value; |
| 3145 } | 3145 } |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3234 }; | 3234 }; |
| 3235 } | 3235 } |
| 3236 | 3236 |
| 3237 class UnlinkedExportPublicBuilder extends Object with _UnlinkedExportPublicMixin
implements UnlinkedExportPublic { | 3237 class UnlinkedExportPublicBuilder extends Object with _UnlinkedExportPublicMixin
implements UnlinkedExportPublic { |
| 3238 bool _finished = false; | 3238 bool _finished = false; |
| 3239 | 3239 |
| 3240 String _uri; | 3240 String _uri; |
| 3241 List<UnlinkedCombinatorBuilder> _combinators; | 3241 List<UnlinkedCombinatorBuilder> _combinators; |
| 3242 | 3242 |
| 3243 @override | 3243 @override |
| 3244 String get uri => _uri ?? ''; | 3244 String get uri => _uri ??= ''; |
| 3245 | 3245 |
| 3246 /** | 3246 /** |
| 3247 * URI used in the source code to reference the exported library. | 3247 * URI used in the source code to reference the exported library. |
| 3248 */ | 3248 */ |
| 3249 void set uri(String _value) { | 3249 void set uri(String _value) { |
| 3250 assert(!_finished); | 3250 assert(!_finished); |
| 3251 _uri = _value; | 3251 _uri = _value; |
| 3252 } | 3252 } |
| 3253 | 3253 |
| 3254 @override | 3254 @override |
| 3255 List<UnlinkedCombinator> get combinators => _combinators ?? const <UnlinkedCom
binator>[]; | 3255 List<UnlinkedCombinatorBuilder> get combinators => _combinators ??= <UnlinkedC
ombinatorBuilder>[]; |
| 3256 | 3256 |
| 3257 /** | 3257 /** |
| 3258 * Combinators contained in this import declaration. | 3258 * Combinators contained in this import declaration. |
| 3259 */ | 3259 */ |
| 3260 void set combinators(List<UnlinkedCombinatorBuilder> _value) { | 3260 void set combinators(List<UnlinkedCombinatorBuilder> _value) { |
| 3261 assert(!_finished); | 3261 assert(!_finished); |
| 3262 _combinators = _value; | 3262 _combinators = _value; |
| 3263 } | 3263 } |
| 3264 | 3264 |
| 3265 UnlinkedExportPublicBuilder({String uri, List<UnlinkedCombinatorBuilder> combi
nators}) | 3265 UnlinkedExportPublicBuilder({String uri, List<UnlinkedCombinatorBuilder> combi
nators}) |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3348 int _offset; | 3348 int _offset; |
| 3349 int _prefixReference; | 3349 int _prefixReference; |
| 3350 List<UnlinkedCombinatorBuilder> _combinators; | 3350 List<UnlinkedCombinatorBuilder> _combinators; |
| 3351 bool _isDeferred; | 3351 bool _isDeferred; |
| 3352 bool _isImplicit; | 3352 bool _isImplicit; |
| 3353 int _uriOffset; | 3353 int _uriOffset; |
| 3354 int _uriEnd; | 3354 int _uriEnd; |
| 3355 int _prefixOffset; | 3355 int _prefixOffset; |
| 3356 | 3356 |
| 3357 @override | 3357 @override |
| 3358 String get uri => _uri ?? ''; | 3358 String get uri => _uri ??= ''; |
| 3359 | 3359 |
| 3360 /** | 3360 /** |
| 3361 * URI used in the source code to reference the imported library. | 3361 * URI used in the source code to reference the imported library. |
| 3362 */ | 3362 */ |
| 3363 void set uri(String _value) { | 3363 void set uri(String _value) { |
| 3364 assert(!_finished); | 3364 assert(!_finished); |
| 3365 _uri = _value; | 3365 _uri = _value; |
| 3366 } | 3366 } |
| 3367 | 3367 |
| 3368 @override | 3368 @override |
| 3369 int get offset => _offset ?? 0; | 3369 int get offset => _offset ??= 0; |
| 3370 | 3370 |
| 3371 /** | 3371 /** |
| 3372 * If [isImplicit] is false, offset of the "import" keyword. If [isImplicit] | 3372 * If [isImplicit] is false, offset of the "import" keyword. If [isImplicit] |
| 3373 * is true, zero. | 3373 * is true, zero. |
| 3374 */ | 3374 */ |
| 3375 void set offset(int _value) { | 3375 void set offset(int _value) { |
| 3376 assert(!_finished); | 3376 assert(!_finished); |
| 3377 assert(_value == null || _value >= 0); | 3377 assert(_value == null || _value >= 0); |
| 3378 _offset = _value; | 3378 _offset = _value; |
| 3379 } | 3379 } |
| 3380 | 3380 |
| 3381 @override | 3381 @override |
| 3382 int get prefixReference => _prefixReference ?? 0; | 3382 int get prefixReference => _prefixReference ??= 0; |
| 3383 | 3383 |
| 3384 /** | 3384 /** |
| 3385 * Index into [UnlinkedUnit.references] of the prefix declared by this | 3385 * Index into [UnlinkedUnit.references] of the prefix declared by this |
| 3386 * import declaration, or zero if this import declaration declares no prefix. | 3386 * import declaration, or zero if this import declaration declares no prefix. |
| 3387 * | 3387 * |
| 3388 * Note that multiple imports can declare the same prefix. | 3388 * Note that multiple imports can declare the same prefix. |
| 3389 */ | 3389 */ |
| 3390 void set prefixReference(int _value) { | 3390 void set prefixReference(int _value) { |
| 3391 assert(!_finished); | 3391 assert(!_finished); |
| 3392 assert(_value == null || _value >= 0); | 3392 assert(_value == null || _value >= 0); |
| 3393 _prefixReference = _value; | 3393 _prefixReference = _value; |
| 3394 } | 3394 } |
| 3395 | 3395 |
| 3396 @override | 3396 @override |
| 3397 List<UnlinkedCombinator> get combinators => _combinators ?? const <UnlinkedCom
binator>[]; | 3397 List<UnlinkedCombinatorBuilder> get combinators => _combinators ??= <UnlinkedC
ombinatorBuilder>[]; |
| 3398 | 3398 |
| 3399 /** | 3399 /** |
| 3400 * Combinators contained in this import declaration. | 3400 * Combinators contained in this import declaration. |
| 3401 */ | 3401 */ |
| 3402 void set combinators(List<UnlinkedCombinatorBuilder> _value) { | 3402 void set combinators(List<UnlinkedCombinatorBuilder> _value) { |
| 3403 assert(!_finished); | 3403 assert(!_finished); |
| 3404 _combinators = _value; | 3404 _combinators = _value; |
| 3405 } | 3405 } |
| 3406 | 3406 |
| 3407 @override | 3407 @override |
| 3408 bool get isDeferred => _isDeferred ?? false; | 3408 bool get isDeferred => _isDeferred ??= false; |
| 3409 | 3409 |
| 3410 /** | 3410 /** |
| 3411 * Indicates whether the import declaration uses the `deferred` keyword. | 3411 * Indicates whether the import declaration uses the `deferred` keyword. |
| 3412 */ | 3412 */ |
| 3413 void set isDeferred(bool _value) { | 3413 void set isDeferred(bool _value) { |
| 3414 assert(!_finished); | 3414 assert(!_finished); |
| 3415 _isDeferred = _value; | 3415 _isDeferred = _value; |
| 3416 } | 3416 } |
| 3417 | 3417 |
| 3418 @override | 3418 @override |
| 3419 bool get isImplicit => _isImplicit ?? false; | 3419 bool get isImplicit => _isImplicit ??= false; |
| 3420 | 3420 |
| 3421 /** | 3421 /** |
| 3422 * Indicates whether the import declaration is implicit. | 3422 * Indicates whether the import declaration is implicit. |
| 3423 */ | 3423 */ |
| 3424 void set isImplicit(bool _value) { | 3424 void set isImplicit(bool _value) { |
| 3425 assert(!_finished); | 3425 assert(!_finished); |
| 3426 _isImplicit = _value; | 3426 _isImplicit = _value; |
| 3427 } | 3427 } |
| 3428 | 3428 |
| 3429 @override | 3429 @override |
| 3430 int get uriOffset => _uriOffset ?? 0; | 3430 int get uriOffset => _uriOffset ??= 0; |
| 3431 | 3431 |
| 3432 /** | 3432 /** |
| 3433 * Offset of the URI string (including quotes) relative to the beginning of | 3433 * Offset of the URI string (including quotes) relative to the beginning of |
| 3434 * the file. If [isImplicit] is true, zero. | 3434 * the file. If [isImplicit] is true, zero. |
| 3435 */ | 3435 */ |
| 3436 void set uriOffset(int _value) { | 3436 void set uriOffset(int _value) { |
| 3437 assert(!_finished); | 3437 assert(!_finished); |
| 3438 assert(_value == null || _value >= 0); | 3438 assert(_value == null || _value >= 0); |
| 3439 _uriOffset = _value; | 3439 _uriOffset = _value; |
| 3440 } | 3440 } |
| 3441 | 3441 |
| 3442 @override | 3442 @override |
| 3443 int get uriEnd => _uriEnd ?? 0; | 3443 int get uriEnd => _uriEnd ??= 0; |
| 3444 | 3444 |
| 3445 /** | 3445 /** |
| 3446 * End of the URI string (including quotes) relative to the beginning of the | 3446 * End of the URI string (including quotes) relative to the beginning of the |
| 3447 * file. If [isImplicit] is true, zero. | 3447 * file. If [isImplicit] is true, zero. |
| 3448 */ | 3448 */ |
| 3449 void set uriEnd(int _value) { | 3449 void set uriEnd(int _value) { |
| 3450 assert(!_finished); | 3450 assert(!_finished); |
| 3451 assert(_value == null || _value >= 0); | 3451 assert(_value == null || _value >= 0); |
| 3452 _uriEnd = _value; | 3452 _uriEnd = _value; |
| 3453 } | 3453 } |
| 3454 | 3454 |
| 3455 @override | 3455 @override |
| 3456 int get prefixOffset => _prefixOffset ?? 0; | 3456 int get prefixOffset => _prefixOffset ??= 0; |
| 3457 | 3457 |
| 3458 /** | 3458 /** |
| 3459 * Offset of the prefix name relative to the beginning of the file, or zero | 3459 * Offset of the prefix name relative to the beginning of the file, or zero |
| 3460 * if there is no prefix. | 3460 * if there is no prefix. |
| 3461 */ | 3461 */ |
| 3462 void set prefixOffset(int _value) { | 3462 void set prefixOffset(int _value) { |
| 3463 assert(!_finished); | 3463 assert(!_finished); |
| 3464 assert(_value == null || _value >= 0); | 3464 assert(_value == null || _value >= 0); |
| 3465 _prefixOffset = _value; | 3465 _prefixOffset = _value; |
| 3466 } | 3466 } |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3675 String _name; | 3675 String _name; |
| 3676 int _nameOffset; | 3676 int _nameOffset; |
| 3677 TypeRefBuilder _type; | 3677 TypeRefBuilder _type; |
| 3678 List<UnlinkedParamBuilder> _parameters; | 3678 List<UnlinkedParamBuilder> _parameters; |
| 3679 UnlinkedParamKind _kind; | 3679 UnlinkedParamKind _kind; |
| 3680 bool _isFunctionTyped; | 3680 bool _isFunctionTyped; |
| 3681 bool _isInitializingFormal; | 3681 bool _isInitializingFormal; |
| 3682 bool _hasImplicitType; | 3682 bool _hasImplicitType; |
| 3683 | 3683 |
| 3684 @override | 3684 @override |
| 3685 String get name => _name ?? ''; | 3685 String get name => _name ??= ''; |
| 3686 | 3686 |
| 3687 /** | 3687 /** |
| 3688 * Name of the parameter. | 3688 * Name of the parameter. |
| 3689 */ | 3689 */ |
| 3690 void set name(String _value) { | 3690 void set name(String _value) { |
| 3691 assert(!_finished); | 3691 assert(!_finished); |
| 3692 _name = _value; | 3692 _name = _value; |
| 3693 } | 3693 } |
| 3694 | 3694 |
| 3695 @override | 3695 @override |
| 3696 int get nameOffset => _nameOffset ?? 0; | 3696 int get nameOffset => _nameOffset ??= 0; |
| 3697 | 3697 |
| 3698 /** | 3698 /** |
| 3699 * Offset of the parameter name relative to the beginning of the file. | 3699 * Offset of the parameter name relative to the beginning of the file. |
| 3700 */ | 3700 */ |
| 3701 void set nameOffset(int _value) { | 3701 void set nameOffset(int _value) { |
| 3702 assert(!_finished); | 3702 assert(!_finished); |
| 3703 assert(_value == null || _value >= 0); | 3703 assert(_value == null || _value >= 0); |
| 3704 _nameOffset = _value; | 3704 _nameOffset = _value; |
| 3705 } | 3705 } |
| 3706 | 3706 |
| 3707 @override | 3707 @override |
| 3708 TypeRef get type => _type; | 3708 TypeRefBuilder get type => _type; |
| 3709 | 3709 |
| 3710 /** | 3710 /** |
| 3711 * If [isFunctionTyped] is `true`, the declared return type. If | 3711 * If [isFunctionTyped] is `true`, the declared return type. If |
| 3712 * [isFunctionTyped] is `false`, the declared type. Absent if | 3712 * [isFunctionTyped] is `false`, the declared type. Absent if |
| 3713 * [isFunctionTyped] is `true` and the declared return type is `void`. Note | 3713 * [isFunctionTyped] is `true` and the declared return type is `void`. Note |
| 3714 * that when strong mode is enabled, the actual type may be different due to | 3714 * that when strong mode is enabled, the actual type may be different due to |
| 3715 * type inference. | 3715 * type inference. |
| 3716 */ | 3716 */ |
| 3717 void set type(TypeRefBuilder _value) { | 3717 void set type(TypeRefBuilder _value) { |
| 3718 assert(!_finished); | 3718 assert(!_finished); |
| 3719 _type = _value; | 3719 _type = _value; |
| 3720 } | 3720 } |
| 3721 | 3721 |
| 3722 @override | 3722 @override |
| 3723 List<UnlinkedParam> get parameters => _parameters ?? const <UnlinkedParam>[]; | 3723 List<UnlinkedParamBuilder> get parameters => _parameters ??= <UnlinkedParamBui
lder>[]; |
| 3724 | 3724 |
| 3725 /** | 3725 /** |
| 3726 * If [isFunctionTyped] is `true`, the parameters of the function type. | 3726 * If [isFunctionTyped] is `true`, the parameters of the function type. |
| 3727 */ | 3727 */ |
| 3728 void set parameters(List<UnlinkedParamBuilder> _value) { | 3728 void set parameters(List<UnlinkedParamBuilder> _value) { |
| 3729 assert(!_finished); | 3729 assert(!_finished); |
| 3730 _parameters = _value; | 3730 _parameters = _value; |
| 3731 } | 3731 } |
| 3732 | 3732 |
| 3733 @override | 3733 @override |
| 3734 UnlinkedParamKind get kind => _kind ?? UnlinkedParamKind.required; | 3734 UnlinkedParamKind get kind => _kind ??= UnlinkedParamKind.required; |
| 3735 | 3735 |
| 3736 /** | 3736 /** |
| 3737 * Kind of the parameter. | 3737 * Kind of the parameter. |
| 3738 */ | 3738 */ |
| 3739 void set kind(UnlinkedParamKind _value) { | 3739 void set kind(UnlinkedParamKind _value) { |
| 3740 assert(!_finished); | 3740 assert(!_finished); |
| 3741 _kind = _value; | 3741 _kind = _value; |
| 3742 } | 3742 } |
| 3743 | 3743 |
| 3744 @override | 3744 @override |
| 3745 bool get isFunctionTyped => _isFunctionTyped ?? false; | 3745 bool get isFunctionTyped => _isFunctionTyped ??= false; |
| 3746 | 3746 |
| 3747 /** | 3747 /** |
| 3748 * Indicates whether this is a function-typed parameter. | 3748 * Indicates whether this is a function-typed parameter. |
| 3749 */ | 3749 */ |
| 3750 void set isFunctionTyped(bool _value) { | 3750 void set isFunctionTyped(bool _value) { |
| 3751 assert(!_finished); | 3751 assert(!_finished); |
| 3752 _isFunctionTyped = _value; | 3752 _isFunctionTyped = _value; |
| 3753 } | 3753 } |
| 3754 | 3754 |
| 3755 @override | 3755 @override |
| 3756 bool get isInitializingFormal => _isInitializingFormal ?? false; | 3756 bool get isInitializingFormal => _isInitializingFormal ??= false; |
| 3757 | 3757 |
| 3758 /** | 3758 /** |
| 3759 * Indicates whether this is an initializing formal parameter (i.e. it is | 3759 * Indicates whether this is an initializing formal parameter (i.e. it is |
| 3760 * declared using `this.` syntax). | 3760 * declared using `this.` syntax). |
| 3761 */ | 3761 */ |
| 3762 void set isInitializingFormal(bool _value) { | 3762 void set isInitializingFormal(bool _value) { |
| 3763 assert(!_finished); | 3763 assert(!_finished); |
| 3764 _isInitializingFormal = _value; | 3764 _isInitializingFormal = _value; |
| 3765 } | 3765 } |
| 3766 | 3766 |
| 3767 @override | 3767 @override |
| 3768 bool get hasImplicitType => _hasImplicitType ?? false; | 3768 bool get hasImplicitType => _hasImplicitType ??= false; |
| 3769 | 3769 |
| 3770 /** | 3770 /** |
| 3771 * Indicates whether this parameter lacks an explicit type declaration. | 3771 * Indicates whether this parameter lacks an explicit type declaration. |
| 3772 * Always false for a function-typed parameter. | 3772 * Always false for a function-typed parameter. |
| 3773 */ | 3773 */ |
| 3774 void set hasImplicitType(bool _value) { | 3774 void set hasImplicitType(bool _value) { |
| 3775 assert(!_finished); | 3775 assert(!_finished); |
| 3776 _hasImplicitType = _value; | 3776 _hasImplicitType = _value; |
| 3777 } | 3777 } |
| 3778 | 3778 |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3966 }; | 3966 }; |
| 3967 } | 3967 } |
| 3968 | 3968 |
| 3969 class UnlinkedPartBuilder extends Object with _UnlinkedPartMixin implements Unli
nkedPart { | 3969 class UnlinkedPartBuilder extends Object with _UnlinkedPartMixin implements Unli
nkedPart { |
| 3970 bool _finished = false; | 3970 bool _finished = false; |
| 3971 | 3971 |
| 3972 int _uriOffset; | 3972 int _uriOffset; |
| 3973 int _uriEnd; | 3973 int _uriEnd; |
| 3974 | 3974 |
| 3975 @override | 3975 @override |
| 3976 int get uriOffset => _uriOffset ?? 0; | 3976 int get uriOffset => _uriOffset ??= 0; |
| 3977 | 3977 |
| 3978 /** | 3978 /** |
| 3979 * Offset of the URI string (including quotes) relative to the beginning of | 3979 * Offset of the URI string (including quotes) relative to the beginning of |
| 3980 * the file. | 3980 * the file. |
| 3981 */ | 3981 */ |
| 3982 void set uriOffset(int _value) { | 3982 void set uriOffset(int _value) { |
| 3983 assert(!_finished); | 3983 assert(!_finished); |
| 3984 assert(_value == null || _value >= 0); | 3984 assert(_value == null || _value >= 0); |
| 3985 _uriOffset = _value; | 3985 _uriOffset = _value; |
| 3986 } | 3986 } |
| 3987 | 3987 |
| 3988 @override | 3988 @override |
| 3989 int get uriEnd => _uriEnd ?? 0; | 3989 int get uriEnd => _uriEnd ??= 0; |
| 3990 | 3990 |
| 3991 /** | 3991 /** |
| 3992 * End of the URI string (including quotes) relative to the beginning of the | 3992 * End of the URI string (including quotes) relative to the beginning of the |
| 3993 * file. | 3993 * file. |
| 3994 */ | 3994 */ |
| 3995 void set uriEnd(int _value) { | 3995 void set uriEnd(int _value) { |
| 3996 assert(!_finished); | 3996 assert(!_finished); |
| 3997 assert(_value == null || _value >= 0); | 3997 assert(_value == null || _value >= 0); |
| 3998 _uriEnd = _value; | 3998 _uriEnd = _value; |
| 3999 } | 3999 } |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4071 } | 4071 } |
| 4072 | 4072 |
| 4073 class UnlinkedPublicNameBuilder extends Object with _UnlinkedPublicNameMixin imp
lements UnlinkedPublicName { | 4073 class UnlinkedPublicNameBuilder extends Object with _UnlinkedPublicNameMixin imp
lements UnlinkedPublicName { |
| 4074 bool _finished = false; | 4074 bool _finished = false; |
| 4075 | 4075 |
| 4076 String _name; | 4076 String _name; |
| 4077 ReferenceKind _kind; | 4077 ReferenceKind _kind; |
| 4078 int _numTypeParameters; | 4078 int _numTypeParameters; |
| 4079 | 4079 |
| 4080 @override | 4080 @override |
| 4081 String get name => _name ?? ''; | 4081 String get name => _name ??= ''; |
| 4082 | 4082 |
| 4083 /** | 4083 /** |
| 4084 * The name itself. | 4084 * The name itself. |
| 4085 */ | 4085 */ |
| 4086 void set name(String _value) { | 4086 void set name(String _value) { |
| 4087 assert(!_finished); | 4087 assert(!_finished); |
| 4088 _name = _value; | 4088 _name = _value; |
| 4089 } | 4089 } |
| 4090 | 4090 |
| 4091 @override | 4091 @override |
| 4092 ReferenceKind get kind => _kind ?? ReferenceKind.classOrEnum; | 4092 ReferenceKind get kind => _kind ??= ReferenceKind.classOrEnum; |
| 4093 | 4093 |
| 4094 /** | 4094 /** |
| 4095 * The kind of object referred to by the name. | 4095 * The kind of object referred to by the name. |
| 4096 */ | 4096 */ |
| 4097 void set kind(ReferenceKind _value) { | 4097 void set kind(ReferenceKind _value) { |
| 4098 assert(!_finished); | 4098 assert(!_finished); |
| 4099 _kind = _value; | 4099 _kind = _value; |
| 4100 } | 4100 } |
| 4101 | 4101 |
| 4102 @override | 4102 @override |
| 4103 int get numTypeParameters => _numTypeParameters ?? 0; | 4103 int get numTypeParameters => _numTypeParameters ??= 0; |
| 4104 | 4104 |
| 4105 /** | 4105 /** |
| 4106 * If the entity being referred to is generic, the number of type parameters | 4106 * If the entity being referred to is generic, the number of type parameters |
| 4107 * it accepts. Otherwise zero. | 4107 * it accepts. Otherwise zero. |
| 4108 */ | 4108 */ |
| 4109 void set numTypeParameters(int _value) { | 4109 void set numTypeParameters(int _value) { |
| 4110 assert(!_finished); | 4110 assert(!_finished); |
| 4111 assert(_value == null || _value >= 0); | 4111 assert(_value == null || _value >= 0); |
| 4112 _numTypeParameters = _value; | 4112 _numTypeParameters = _value; |
| 4113 } | 4113 } |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4216 } | 4216 } |
| 4217 | 4217 |
| 4218 class UnlinkedPublicNamespaceBuilder extends Object with _UnlinkedPublicNamespac
eMixin implements UnlinkedPublicNamespace { | 4218 class UnlinkedPublicNamespaceBuilder extends Object with _UnlinkedPublicNamespac
eMixin implements UnlinkedPublicNamespace { |
| 4219 bool _finished = false; | 4219 bool _finished = false; |
| 4220 | 4220 |
| 4221 List<UnlinkedPublicNameBuilder> _names; | 4221 List<UnlinkedPublicNameBuilder> _names; |
| 4222 List<UnlinkedExportPublicBuilder> _exports; | 4222 List<UnlinkedExportPublicBuilder> _exports; |
| 4223 List<String> _parts; | 4223 List<String> _parts; |
| 4224 | 4224 |
| 4225 @override | 4225 @override |
| 4226 List<UnlinkedPublicName> get names => _names ?? const <UnlinkedPublicName>[]; | 4226 List<UnlinkedPublicNameBuilder> get names => _names ??= <UnlinkedPublicNameBui
lder>[]; |
| 4227 | 4227 |
| 4228 /** | 4228 /** |
| 4229 * Public names defined in the compilation unit. | 4229 * Public names defined in the compilation unit. |
| 4230 * | 4230 * |
| 4231 * TODO(paulberry): consider sorting these names to reduce unnecessary | 4231 * TODO(paulberry): consider sorting these names to reduce unnecessary |
| 4232 * relinking. | 4232 * relinking. |
| 4233 */ | 4233 */ |
| 4234 void set names(List<UnlinkedPublicNameBuilder> _value) { | 4234 void set names(List<UnlinkedPublicNameBuilder> _value) { |
| 4235 assert(!_finished); | 4235 assert(!_finished); |
| 4236 _names = _value; | 4236 _names = _value; |
| 4237 } | 4237 } |
| 4238 | 4238 |
| 4239 @override | 4239 @override |
| 4240 List<UnlinkedExportPublic> get exports => _exports ?? const <UnlinkedExportPub
lic>[]; | 4240 List<UnlinkedExportPublicBuilder> get exports => _exports ??= <UnlinkedExportP
ublicBuilder>[]; |
| 4241 | 4241 |
| 4242 /** | 4242 /** |
| 4243 * Export declarations in the compilation unit. | 4243 * Export declarations in the compilation unit. |
| 4244 */ | 4244 */ |
| 4245 void set exports(List<UnlinkedExportPublicBuilder> _value) { | 4245 void set exports(List<UnlinkedExportPublicBuilder> _value) { |
| 4246 assert(!_finished); | 4246 assert(!_finished); |
| 4247 _exports = _value; | 4247 _exports = _value; |
| 4248 } | 4248 } |
| 4249 | 4249 |
| 4250 @override | 4250 @override |
| 4251 List<String> get parts => _parts ?? const <String>[]; | 4251 List<String> get parts => _parts ??= <String>[]; |
| 4252 | 4252 |
| 4253 /** | 4253 /** |
| 4254 * URIs referenced by part declarations in the compilation unit. | 4254 * URIs referenced by part declarations in the compilation unit. |
| 4255 */ | 4255 */ |
| 4256 void set parts(List<String> _value) { | 4256 void set parts(List<String> _value) { |
| 4257 assert(!_finished); | 4257 assert(!_finished); |
| 4258 _parts = _value; | 4258 _parts = _value; |
| 4259 } | 4259 } |
| 4260 | 4260 |
| 4261 UnlinkedPublicNamespaceBuilder({List<UnlinkedPublicNameBuilder> names, List<Un
linkedExportPublicBuilder> exports, List<String> parts}) | 4261 UnlinkedPublicNamespaceBuilder({List<UnlinkedPublicNameBuilder> names, List<Un
linkedExportPublicBuilder> exports, List<String> parts}) |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4371 }; | 4371 }; |
| 4372 } | 4372 } |
| 4373 | 4373 |
| 4374 class UnlinkedReferenceBuilder extends Object with _UnlinkedReferenceMixin imple
ments UnlinkedReference { | 4374 class UnlinkedReferenceBuilder extends Object with _UnlinkedReferenceMixin imple
ments UnlinkedReference { |
| 4375 bool _finished = false; | 4375 bool _finished = false; |
| 4376 | 4376 |
| 4377 String _name; | 4377 String _name; |
| 4378 int _prefixReference; | 4378 int _prefixReference; |
| 4379 | 4379 |
| 4380 @override | 4380 @override |
| 4381 String get name => _name ?? ''; | 4381 String get name => _name ??= ''; |
| 4382 | 4382 |
| 4383 /** | 4383 /** |
| 4384 * Name of the entity being referred to. The empty string refers to the | 4384 * Name of the entity being referred to. The empty string refers to the |
| 4385 * pseudo-type `dynamic`. | 4385 * pseudo-type `dynamic`. |
| 4386 */ | 4386 */ |
| 4387 void set name(String _value) { | 4387 void set name(String _value) { |
| 4388 assert(!_finished); | 4388 assert(!_finished); |
| 4389 _name = _value; | 4389 _name = _value; |
| 4390 } | 4390 } |
| 4391 | 4391 |
| 4392 @override | 4392 @override |
| 4393 int get prefixReference => _prefixReference ?? 0; | 4393 int get prefixReference => _prefixReference ??= 0; |
| 4394 | 4394 |
| 4395 /** | 4395 /** |
| 4396 * Prefix used to refer to the entity, or zero if no prefix is used. This is | 4396 * Prefix used to refer to the entity, or zero if no prefix is used. This is |
| 4397 * an index into [UnlinkedUnit.references]. | 4397 * an index into [UnlinkedUnit.references]. |
| 4398 * | 4398 * |
| 4399 * Prefix references must always point backward; that is, for all i, if | 4399 * Prefix references must always point backward; that is, for all i, if |
| 4400 * UnlinkedUnit.references[i].prefixReference != 0, then | 4400 * UnlinkedUnit.references[i].prefixReference != 0, then |
| 4401 * UnlinkedUnit.references[i].prefixReference < i. | 4401 * UnlinkedUnit.references[i].prefixReference < i. |
| 4402 */ | 4402 */ |
| 4403 void set prefixReference(int _value) { | 4403 void set prefixReference(int _value) { |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4491 bool _finished = false; | 4491 bool _finished = false; |
| 4492 | 4492 |
| 4493 String _name; | 4493 String _name; |
| 4494 int _nameOffset; | 4494 int _nameOffset; |
| 4495 UnlinkedDocumentationCommentBuilder _documentationComment; | 4495 UnlinkedDocumentationCommentBuilder _documentationComment; |
| 4496 List<UnlinkedTypeParamBuilder> _typeParameters; | 4496 List<UnlinkedTypeParamBuilder> _typeParameters; |
| 4497 TypeRefBuilder _returnType; | 4497 TypeRefBuilder _returnType; |
| 4498 List<UnlinkedParamBuilder> _parameters; | 4498 List<UnlinkedParamBuilder> _parameters; |
| 4499 | 4499 |
| 4500 @override | 4500 @override |
| 4501 String get name => _name ?? ''; | 4501 String get name => _name ??= ''; |
| 4502 | 4502 |
| 4503 /** | 4503 /** |
| 4504 * Name of the typedef. | 4504 * Name of the typedef. |
| 4505 */ | 4505 */ |
| 4506 void set name(String _value) { | 4506 void set name(String _value) { |
| 4507 assert(!_finished); | 4507 assert(!_finished); |
| 4508 _name = _value; | 4508 _name = _value; |
| 4509 } | 4509 } |
| 4510 | 4510 |
| 4511 @override | 4511 @override |
| 4512 int get nameOffset => _nameOffset ?? 0; | 4512 int get nameOffset => _nameOffset ??= 0; |
| 4513 | 4513 |
| 4514 /** | 4514 /** |
| 4515 * Offset of the typedef name relative to the beginning of the file. | 4515 * Offset of the typedef name relative to the beginning of the file. |
| 4516 */ | 4516 */ |
| 4517 void set nameOffset(int _value) { | 4517 void set nameOffset(int _value) { |
| 4518 assert(!_finished); | 4518 assert(!_finished); |
| 4519 assert(_value == null || _value >= 0); | 4519 assert(_value == null || _value >= 0); |
| 4520 _nameOffset = _value; | 4520 _nameOffset = _value; |
| 4521 } | 4521 } |
| 4522 | 4522 |
| 4523 @override | 4523 @override |
| 4524 UnlinkedDocumentationComment get documentationComment => _documentationComment
; | 4524 UnlinkedDocumentationCommentBuilder get documentationComment => _documentation
Comment; |
| 4525 | 4525 |
| 4526 /** | 4526 /** |
| 4527 * Documentation comment for the typedef, or `null` if there is no | 4527 * Documentation comment for the typedef, or `null` if there is no |
| 4528 * documentation comment. | 4528 * documentation comment. |
| 4529 */ | 4529 */ |
| 4530 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { | 4530 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { |
| 4531 assert(!_finished); | 4531 assert(!_finished); |
| 4532 _documentationComment = _value; | 4532 _documentationComment = _value; |
| 4533 } | 4533 } |
| 4534 | 4534 |
| 4535 @override | 4535 @override |
| 4536 List<UnlinkedTypeParam> get typeParameters => _typeParameters ?? const <Unlink
edTypeParam>[]; | 4536 List<UnlinkedTypeParamBuilder> get typeParameters => _typeParameters ??= <Unli
nkedTypeParamBuilder>[]; |
| 4537 | 4537 |
| 4538 /** | 4538 /** |
| 4539 * Type parameters of the typedef, if any. | 4539 * Type parameters of the typedef, if any. |
| 4540 */ | 4540 */ |
| 4541 void set typeParameters(List<UnlinkedTypeParamBuilder> _value) { | 4541 void set typeParameters(List<UnlinkedTypeParamBuilder> _value) { |
| 4542 assert(!_finished); | 4542 assert(!_finished); |
| 4543 _typeParameters = _value; | 4543 _typeParameters = _value; |
| 4544 } | 4544 } |
| 4545 | 4545 |
| 4546 @override | 4546 @override |
| 4547 TypeRef get returnType => _returnType; | 4547 TypeRefBuilder get returnType => _returnType; |
| 4548 | 4548 |
| 4549 /** | 4549 /** |
| 4550 * Return type of the typedef. Absent if the return type is `void`. | 4550 * Return type of the typedef. Absent if the return type is `void`. |
| 4551 */ | 4551 */ |
| 4552 void set returnType(TypeRefBuilder _value) { | 4552 void set returnType(TypeRefBuilder _value) { |
| 4553 assert(!_finished); | 4553 assert(!_finished); |
| 4554 _returnType = _value; | 4554 _returnType = _value; |
| 4555 } | 4555 } |
| 4556 | 4556 |
| 4557 @override | 4557 @override |
| 4558 List<UnlinkedParam> get parameters => _parameters ?? const <UnlinkedParam>[]; | 4558 List<UnlinkedParamBuilder> get parameters => _parameters ??= <UnlinkedParamBui
lder>[]; |
| 4559 | 4559 |
| 4560 /** | 4560 /** |
| 4561 * Parameters of the executable, if any. | 4561 * Parameters of the executable, if any. |
| 4562 */ | 4562 */ |
| 4563 void set parameters(List<UnlinkedParamBuilder> _value) { | 4563 void set parameters(List<UnlinkedParamBuilder> _value) { |
| 4564 assert(!_finished); | 4564 assert(!_finished); |
| 4565 _parameters = _value; | 4565 _parameters = _value; |
| 4566 } | 4566 } |
| 4567 | 4567 |
| 4568 UnlinkedTypedefBuilder({String name, int nameOffset, UnlinkedDocumentationComm
entBuilder documentationComment, List<UnlinkedTypeParamBuilder> typeParameters,
TypeRefBuilder returnType, List<UnlinkedParamBuilder> parameters}) | 4568 UnlinkedTypedefBuilder({String name, int nameOffset, UnlinkedDocumentationComm
entBuilder documentationComment, List<UnlinkedTypeParamBuilder> typeParameters,
TypeRefBuilder returnType, List<UnlinkedParamBuilder> parameters}) |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4725 } | 4725 } |
| 4726 | 4726 |
| 4727 class UnlinkedTypeParamBuilder extends Object with _UnlinkedTypeParamMixin imple
ments UnlinkedTypeParam { | 4727 class UnlinkedTypeParamBuilder extends Object with _UnlinkedTypeParamMixin imple
ments UnlinkedTypeParam { |
| 4728 bool _finished = false; | 4728 bool _finished = false; |
| 4729 | 4729 |
| 4730 String _name; | 4730 String _name; |
| 4731 int _nameOffset; | 4731 int _nameOffset; |
| 4732 TypeRefBuilder _bound; | 4732 TypeRefBuilder _bound; |
| 4733 | 4733 |
| 4734 @override | 4734 @override |
| 4735 String get name => _name ?? ''; | 4735 String get name => _name ??= ''; |
| 4736 | 4736 |
| 4737 /** | 4737 /** |
| 4738 * Name of the type parameter. | 4738 * Name of the type parameter. |
| 4739 */ | 4739 */ |
| 4740 void set name(String _value) { | 4740 void set name(String _value) { |
| 4741 assert(!_finished); | 4741 assert(!_finished); |
| 4742 _name = _value; | 4742 _name = _value; |
| 4743 } | 4743 } |
| 4744 | 4744 |
| 4745 @override | 4745 @override |
| 4746 int get nameOffset => _nameOffset ?? 0; | 4746 int get nameOffset => _nameOffset ??= 0; |
| 4747 | 4747 |
| 4748 /** | 4748 /** |
| 4749 * Offset of the type parameter name relative to the beginning of the file. | 4749 * Offset of the type parameter name relative to the beginning of the file. |
| 4750 */ | 4750 */ |
| 4751 void set nameOffset(int _value) { | 4751 void set nameOffset(int _value) { |
| 4752 assert(!_finished); | 4752 assert(!_finished); |
| 4753 assert(_value == null || _value >= 0); | 4753 assert(_value == null || _value >= 0); |
| 4754 _nameOffset = _value; | 4754 _nameOffset = _value; |
| 4755 } | 4755 } |
| 4756 | 4756 |
| 4757 @override | 4757 @override |
| 4758 TypeRef get bound => _bound; | 4758 TypeRefBuilder get bound => _bound; |
| 4759 | 4759 |
| 4760 /** | 4760 /** |
| 4761 * Bound of the type parameter, if a bound is explicitly declared. Otherwise | 4761 * Bound of the type parameter, if a bound is explicitly declared. Otherwise |
| 4762 * null. | 4762 * null. |
| 4763 */ | 4763 */ |
| 4764 void set bound(TypeRefBuilder _value) { | 4764 void set bound(TypeRefBuilder _value) { |
| 4765 assert(!_finished); | 4765 assert(!_finished); |
| 4766 _bound = _value; | 4766 _bound = _value; |
| 4767 } | 4767 } |
| 4768 | 4768 |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4874 List<UnlinkedClassBuilder> _classes; | 4874 List<UnlinkedClassBuilder> _classes; |
| 4875 List<UnlinkedEnumBuilder> _enums; | 4875 List<UnlinkedEnumBuilder> _enums; |
| 4876 List<UnlinkedExecutableBuilder> _executables; | 4876 List<UnlinkedExecutableBuilder> _executables; |
| 4877 List<UnlinkedExportNonPublicBuilder> _exports; | 4877 List<UnlinkedExportNonPublicBuilder> _exports; |
| 4878 List<UnlinkedImportBuilder> _imports; | 4878 List<UnlinkedImportBuilder> _imports; |
| 4879 List<UnlinkedPartBuilder> _parts; | 4879 List<UnlinkedPartBuilder> _parts; |
| 4880 List<UnlinkedTypedefBuilder> _typedefs; | 4880 List<UnlinkedTypedefBuilder> _typedefs; |
| 4881 List<UnlinkedVariableBuilder> _variables; | 4881 List<UnlinkedVariableBuilder> _variables; |
| 4882 | 4882 |
| 4883 @override | 4883 @override |
| 4884 String get libraryName => _libraryName ?? ''; | 4884 String get libraryName => _libraryName ??= ''; |
| 4885 | 4885 |
| 4886 /** | 4886 /** |
| 4887 * Name of the library (from a "library" declaration, if present). | 4887 * Name of the library (from a "library" declaration, if present). |
| 4888 */ | 4888 */ |
| 4889 void set libraryName(String _value) { | 4889 void set libraryName(String _value) { |
| 4890 assert(!_finished); | 4890 assert(!_finished); |
| 4891 _libraryName = _value; | 4891 _libraryName = _value; |
| 4892 } | 4892 } |
| 4893 | 4893 |
| 4894 @override | 4894 @override |
| 4895 int get libraryNameOffset => _libraryNameOffset ?? 0; | 4895 int get libraryNameOffset => _libraryNameOffset ??= 0; |
| 4896 | 4896 |
| 4897 /** | 4897 /** |
| 4898 * Offset of the library name relative to the beginning of the file (or 0 if | 4898 * Offset of the library name relative to the beginning of the file (or 0 if |
| 4899 * the library has no name). | 4899 * the library has no name). |
| 4900 */ | 4900 */ |
| 4901 void set libraryNameOffset(int _value) { | 4901 void set libraryNameOffset(int _value) { |
| 4902 assert(!_finished); | 4902 assert(!_finished); |
| 4903 assert(_value == null || _value >= 0); | 4903 assert(_value == null || _value >= 0); |
| 4904 _libraryNameOffset = _value; | 4904 _libraryNameOffset = _value; |
| 4905 } | 4905 } |
| 4906 | 4906 |
| 4907 @override | 4907 @override |
| 4908 int get libraryNameLength => _libraryNameLength ?? 0; | 4908 int get libraryNameLength => _libraryNameLength ??= 0; |
| 4909 | 4909 |
| 4910 /** | 4910 /** |
| 4911 * Length of the library name as it appears in the source code (or 0 if the | 4911 * Length of the library name as it appears in the source code (or 0 if the |
| 4912 * library has no name). | 4912 * library has no name). |
| 4913 */ | 4913 */ |
| 4914 void set libraryNameLength(int _value) { | 4914 void set libraryNameLength(int _value) { |
| 4915 assert(!_finished); | 4915 assert(!_finished); |
| 4916 assert(_value == null || _value >= 0); | 4916 assert(_value == null || _value >= 0); |
| 4917 _libraryNameLength = _value; | 4917 _libraryNameLength = _value; |
| 4918 } | 4918 } |
| 4919 | 4919 |
| 4920 @override | 4920 @override |
| 4921 UnlinkedDocumentationComment get libraryDocumentationComment => _libraryDocume
ntationComment; | 4921 UnlinkedDocumentationCommentBuilder get libraryDocumentationComment => _librar
yDocumentationComment; |
| 4922 | 4922 |
| 4923 /** | 4923 /** |
| 4924 * Documentation comment for the library, or `null` if there is no | 4924 * Documentation comment for the library, or `null` if there is no |
| 4925 * documentation comment. | 4925 * documentation comment. |
| 4926 */ | 4926 */ |
| 4927 void set libraryDocumentationComment(UnlinkedDocumentationCommentBuilder _valu
e) { | 4927 void set libraryDocumentationComment(UnlinkedDocumentationCommentBuilder _valu
e) { |
| 4928 assert(!_finished); | 4928 assert(!_finished); |
| 4929 _libraryDocumentationComment = _value; | 4929 _libraryDocumentationComment = _value; |
| 4930 } | 4930 } |
| 4931 | 4931 |
| 4932 @override | 4932 @override |
| 4933 UnlinkedPublicNamespace get publicNamespace => _publicNamespace; | 4933 UnlinkedPublicNamespaceBuilder get publicNamespace => _publicNamespace; |
| 4934 | 4934 |
| 4935 /** | 4935 /** |
| 4936 * Unlinked public namespace of this compilation unit. | 4936 * Unlinked public namespace of this compilation unit. |
| 4937 */ | 4937 */ |
| 4938 void set publicNamespace(UnlinkedPublicNamespaceBuilder _value) { | 4938 void set publicNamespace(UnlinkedPublicNamespaceBuilder _value) { |
| 4939 assert(!_finished); | 4939 assert(!_finished); |
| 4940 _publicNamespace = _value; | 4940 _publicNamespace = _value; |
| 4941 } | 4941 } |
| 4942 | 4942 |
| 4943 @override | 4943 @override |
| 4944 List<UnlinkedReference> get references => _references ?? const <UnlinkedRefere
nce>[]; | 4944 List<UnlinkedReferenceBuilder> get references => _references ??= <UnlinkedRefe
renceBuilder>[]; |
| 4945 | 4945 |
| 4946 /** | 4946 /** |
| 4947 * Top level and prefixed names referred to by this compilation unit. The | 4947 * Top level and prefixed names referred to by this compilation unit. The |
| 4948 * zeroth element of this array is always populated and always represents a | 4948 * zeroth element of this array is always populated and always represents a |
| 4949 * reference to the pseudo-type "dynamic". | 4949 * reference to the pseudo-type "dynamic". |
| 4950 */ | 4950 */ |
| 4951 void set references(List<UnlinkedReferenceBuilder> _value) { | 4951 void set references(List<UnlinkedReferenceBuilder> _value) { |
| 4952 assert(!_finished); | 4952 assert(!_finished); |
| 4953 _references = _value; | 4953 _references = _value; |
| 4954 } | 4954 } |
| 4955 | 4955 |
| 4956 @override | 4956 @override |
| 4957 List<UnlinkedClass> get classes => _classes ?? const <UnlinkedClass>[]; | 4957 List<UnlinkedClassBuilder> get classes => _classes ??= <UnlinkedClassBuilder>[
]; |
| 4958 | 4958 |
| 4959 /** | 4959 /** |
| 4960 * Classes declared in the compilation unit. | 4960 * Classes declared in the compilation unit. |
| 4961 */ | 4961 */ |
| 4962 void set classes(List<UnlinkedClassBuilder> _value) { | 4962 void set classes(List<UnlinkedClassBuilder> _value) { |
| 4963 assert(!_finished); | 4963 assert(!_finished); |
| 4964 _classes = _value; | 4964 _classes = _value; |
| 4965 } | 4965 } |
| 4966 | 4966 |
| 4967 @override | 4967 @override |
| 4968 List<UnlinkedEnum> get enums => _enums ?? const <UnlinkedEnum>[]; | 4968 List<UnlinkedEnumBuilder> get enums => _enums ??= <UnlinkedEnumBuilder>[]; |
| 4969 | 4969 |
| 4970 /** | 4970 /** |
| 4971 * Enums declared in the compilation unit. | 4971 * Enums declared in the compilation unit. |
| 4972 */ | 4972 */ |
| 4973 void set enums(List<UnlinkedEnumBuilder> _value) { | 4973 void set enums(List<UnlinkedEnumBuilder> _value) { |
| 4974 assert(!_finished); | 4974 assert(!_finished); |
| 4975 _enums = _value; | 4975 _enums = _value; |
| 4976 } | 4976 } |
| 4977 | 4977 |
| 4978 @override | 4978 @override |
| 4979 List<UnlinkedExecutable> get executables => _executables ?? const <UnlinkedExe
cutable>[]; | 4979 List<UnlinkedExecutableBuilder> get executables => _executables ??= <UnlinkedE
xecutableBuilder>[]; |
| 4980 | 4980 |
| 4981 /** | 4981 /** |
| 4982 * Top level executable objects (functions, getters, and setters) declared in | 4982 * Top level executable objects (functions, getters, and setters) declared in |
| 4983 * the compilation unit. | 4983 * the compilation unit. |
| 4984 */ | 4984 */ |
| 4985 void set executables(List<UnlinkedExecutableBuilder> _value) { | 4985 void set executables(List<UnlinkedExecutableBuilder> _value) { |
| 4986 assert(!_finished); | 4986 assert(!_finished); |
| 4987 _executables = _value; | 4987 _executables = _value; |
| 4988 } | 4988 } |
| 4989 | 4989 |
| 4990 @override | 4990 @override |
| 4991 List<UnlinkedExportNonPublic> get exports => _exports ?? const <UnlinkedExport
NonPublic>[]; | 4991 List<UnlinkedExportNonPublicBuilder> get exports => _exports ??= <UnlinkedExpo
rtNonPublicBuilder>[]; |
| 4992 | 4992 |
| 4993 /** | 4993 /** |
| 4994 * Export declarations in the compilation unit. | 4994 * Export declarations in the compilation unit. |
| 4995 */ | 4995 */ |
| 4996 void set exports(List<UnlinkedExportNonPublicBuilder> _value) { | 4996 void set exports(List<UnlinkedExportNonPublicBuilder> _value) { |
| 4997 assert(!_finished); | 4997 assert(!_finished); |
| 4998 _exports = _value; | 4998 _exports = _value; |
| 4999 } | 4999 } |
| 5000 | 5000 |
| 5001 @override | 5001 @override |
| 5002 List<UnlinkedImport> get imports => _imports ?? const <UnlinkedImport>[]; | 5002 List<UnlinkedImportBuilder> get imports => _imports ??= <UnlinkedImportBuilder
>[]; |
| 5003 | 5003 |
| 5004 /** | 5004 /** |
| 5005 * Import declarations in the compilation unit. | 5005 * Import declarations in the compilation unit. |
| 5006 */ | 5006 */ |
| 5007 void set imports(List<UnlinkedImportBuilder> _value) { | 5007 void set imports(List<UnlinkedImportBuilder> _value) { |
| 5008 assert(!_finished); | 5008 assert(!_finished); |
| 5009 _imports = _value; | 5009 _imports = _value; |
| 5010 } | 5010 } |
| 5011 | 5011 |
| 5012 @override | 5012 @override |
| 5013 List<UnlinkedPart> get parts => _parts ?? const <UnlinkedPart>[]; | 5013 List<UnlinkedPartBuilder> get parts => _parts ??= <UnlinkedPartBuilder>[]; |
| 5014 | 5014 |
| 5015 /** | 5015 /** |
| 5016 * Part declarations in the compilation unit. | 5016 * Part declarations in the compilation unit. |
| 5017 */ | 5017 */ |
| 5018 void set parts(List<UnlinkedPartBuilder> _value) { | 5018 void set parts(List<UnlinkedPartBuilder> _value) { |
| 5019 assert(!_finished); | 5019 assert(!_finished); |
| 5020 _parts = _value; | 5020 _parts = _value; |
| 5021 } | 5021 } |
| 5022 | 5022 |
| 5023 @override | 5023 @override |
| 5024 List<UnlinkedTypedef> get typedefs => _typedefs ?? const <UnlinkedTypedef>[]; | 5024 List<UnlinkedTypedefBuilder> get typedefs => _typedefs ??= <UnlinkedTypedefBui
lder>[]; |
| 5025 | 5025 |
| 5026 /** | 5026 /** |
| 5027 * Typedefs declared in the compilation unit. | 5027 * Typedefs declared in the compilation unit. |
| 5028 */ | 5028 */ |
| 5029 void set typedefs(List<UnlinkedTypedefBuilder> _value) { | 5029 void set typedefs(List<UnlinkedTypedefBuilder> _value) { |
| 5030 assert(!_finished); | 5030 assert(!_finished); |
| 5031 _typedefs = _value; | 5031 _typedefs = _value; |
| 5032 } | 5032 } |
| 5033 | 5033 |
| 5034 @override | 5034 @override |
| 5035 List<UnlinkedVariable> get variables => _variables ?? const <UnlinkedVariable>
[]; | 5035 List<UnlinkedVariableBuilder> get variables => _variables ??= <UnlinkedVariabl
eBuilder>[]; |
| 5036 | 5036 |
| 5037 /** | 5037 /** |
| 5038 * Top level variables declared in the compilation unit. | 5038 * Top level variables declared in the compilation unit. |
| 5039 */ | 5039 */ |
| 5040 void set variables(List<UnlinkedVariableBuilder> _value) { | 5040 void set variables(List<UnlinkedVariableBuilder> _value) { |
| 5041 assert(!_finished); | 5041 assert(!_finished); |
| 5042 _variables = _value; | 5042 _variables = _value; |
| 5043 } | 5043 } |
| 5044 | 5044 |
| 5045 UnlinkedUnitBuilder({String libraryName, int libraryNameOffset, int libraryNam
eLength, UnlinkedDocumentationCommentBuilder libraryDocumentationComment, Unlink
edPublicNamespaceBuilder publicNamespace, List<UnlinkedReferenceBuilder> referen
ces, List<UnlinkedClassBuilder> classes, List<UnlinkedEnumBuilder> enums, List<U
nlinkedExecutableBuilder> executables, List<UnlinkedExportNonPublicBuilder> expo
rts, List<UnlinkedImportBuilder> imports, List<UnlinkedPartBuilder> parts, List<
UnlinkedTypedefBuilder> typedefs, List<UnlinkedVariableBuilder> variables}) | 5045 UnlinkedUnitBuilder({String libraryName, int libraryNameOffset, int libraryNam
eLength, UnlinkedDocumentationCommentBuilder libraryDocumentationComment, Unlink
edPublicNamespaceBuilder publicNamespace, List<UnlinkedReferenceBuilder> referen
ces, List<UnlinkedClassBuilder> classes, List<UnlinkedEnumBuilder> enums, List<U
nlinkedExecutableBuilder> executables, List<UnlinkedExportNonPublicBuilder> expo
rts, List<UnlinkedImportBuilder> imports, List<UnlinkedPartBuilder> parts, List<
UnlinkedTypedefBuilder> typedefs, List<UnlinkedVariableBuilder> variables}) |
| (...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5387 UnlinkedDocumentationCommentBuilder _documentationComment; | 5387 UnlinkedDocumentationCommentBuilder _documentationComment; |
| 5388 TypeRefBuilder _type; | 5388 TypeRefBuilder _type; |
| 5389 UnlinkedConstBuilder _constExpr; | 5389 UnlinkedConstBuilder _constExpr; |
| 5390 bool _isStatic; | 5390 bool _isStatic; |
| 5391 bool _isFinal; | 5391 bool _isFinal; |
| 5392 bool _isConst; | 5392 bool _isConst; |
| 5393 bool _hasImplicitType; | 5393 bool _hasImplicitType; |
| 5394 int _propagatedTypeSlot; | 5394 int _propagatedTypeSlot; |
| 5395 | 5395 |
| 5396 @override | 5396 @override |
| 5397 String get name => _name ?? ''; | 5397 String get name => _name ??= ''; |
| 5398 | 5398 |
| 5399 /** | 5399 /** |
| 5400 * Name of the variable. | 5400 * Name of the variable. |
| 5401 */ | 5401 */ |
| 5402 void set name(String _value) { | 5402 void set name(String _value) { |
| 5403 assert(!_finished); | 5403 assert(!_finished); |
| 5404 _name = _value; | 5404 _name = _value; |
| 5405 } | 5405 } |
| 5406 | 5406 |
| 5407 @override | 5407 @override |
| 5408 int get nameOffset => _nameOffset ?? 0; | 5408 int get nameOffset => _nameOffset ??= 0; |
| 5409 | 5409 |
| 5410 /** | 5410 /** |
| 5411 * Offset of the variable name relative to the beginning of the file. | 5411 * Offset of the variable name relative to the beginning of the file. |
| 5412 */ | 5412 */ |
| 5413 void set nameOffset(int _value) { | 5413 void set nameOffset(int _value) { |
| 5414 assert(!_finished); | 5414 assert(!_finished); |
| 5415 assert(_value == null || _value >= 0); | 5415 assert(_value == null || _value >= 0); |
| 5416 _nameOffset = _value; | 5416 _nameOffset = _value; |
| 5417 } | 5417 } |
| 5418 | 5418 |
| 5419 @override | 5419 @override |
| 5420 UnlinkedDocumentationComment get documentationComment => _documentationComment
; | 5420 UnlinkedDocumentationCommentBuilder get documentationComment => _documentation
Comment; |
| 5421 | 5421 |
| 5422 /** | 5422 /** |
| 5423 * Documentation comment for the variable, or `null` if there is no | 5423 * Documentation comment for the variable, or `null` if there is no |
| 5424 * documentation comment. | 5424 * documentation comment. |
| 5425 */ | 5425 */ |
| 5426 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { | 5426 void set documentationComment(UnlinkedDocumentationCommentBuilder _value) { |
| 5427 assert(!_finished); | 5427 assert(!_finished); |
| 5428 _documentationComment = _value; | 5428 _documentationComment = _value; |
| 5429 } | 5429 } |
| 5430 | 5430 |
| 5431 @override | 5431 @override |
| 5432 TypeRef get type => _type; | 5432 TypeRefBuilder get type => _type; |
| 5433 | 5433 |
| 5434 /** | 5434 /** |
| 5435 * Declared type of the variable. Note that when strong mode is enabled, the | 5435 * Declared type of the variable. Note that when strong mode is enabled, the |
| 5436 * actual type of the variable may be different due to type inference. | 5436 * actual type of the variable may be different due to type inference. |
| 5437 */ | 5437 */ |
| 5438 void set type(TypeRefBuilder _value) { | 5438 void set type(TypeRefBuilder _value) { |
| 5439 assert(!_finished); | 5439 assert(!_finished); |
| 5440 _type = _value; | 5440 _type = _value; |
| 5441 } | 5441 } |
| 5442 | 5442 |
| 5443 @override | 5443 @override |
| 5444 UnlinkedConst get constExpr => _constExpr; | 5444 UnlinkedConstBuilder get constExpr => _constExpr; |
| 5445 | 5445 |
| 5446 /** | 5446 /** |
| 5447 * If [isConst] is true, and the variable has an initializer, the constant | 5447 * If [isConst] is true, and the variable has an initializer, the constant |
| 5448 * expression in the initializer. | 5448 * expression in the initializer. |
| 5449 */ | 5449 */ |
| 5450 void set constExpr(UnlinkedConstBuilder _value) { | 5450 void set constExpr(UnlinkedConstBuilder _value) { |
| 5451 assert(!_finished); | 5451 assert(!_finished); |
| 5452 _constExpr = _value; | 5452 _constExpr = _value; |
| 5453 } | 5453 } |
| 5454 | 5454 |
| 5455 @override | 5455 @override |
| 5456 bool get isStatic => _isStatic ?? false; | 5456 bool get isStatic => _isStatic ??= false; |
| 5457 | 5457 |
| 5458 /** | 5458 /** |
| 5459 * Indicates whether the variable is declared using the `static` keyword. | 5459 * Indicates whether the variable is declared using the `static` keyword. |
| 5460 * | 5460 * |
| 5461 * Note that for top level variables, this flag is false, since they are not | 5461 * Note that for top level variables, this flag is false, since they are not |
| 5462 * declared using the `static` keyword (even though they are considered | 5462 * declared using the `static` keyword (even though they are considered |
| 5463 * static for semantic purposes). | 5463 * static for semantic purposes). |
| 5464 */ | 5464 */ |
| 5465 void set isStatic(bool _value) { | 5465 void set isStatic(bool _value) { |
| 5466 assert(!_finished); | 5466 assert(!_finished); |
| 5467 _isStatic = _value; | 5467 _isStatic = _value; |
| 5468 } | 5468 } |
| 5469 | 5469 |
| 5470 @override | 5470 @override |
| 5471 bool get isFinal => _isFinal ?? false; | 5471 bool get isFinal => _isFinal ??= false; |
| 5472 | 5472 |
| 5473 /** | 5473 /** |
| 5474 * Indicates whether the variable is declared using the `final` keyword. | 5474 * Indicates whether the variable is declared using the `final` keyword. |
| 5475 */ | 5475 */ |
| 5476 void set isFinal(bool _value) { | 5476 void set isFinal(bool _value) { |
| 5477 assert(!_finished); | 5477 assert(!_finished); |
| 5478 _isFinal = _value; | 5478 _isFinal = _value; |
| 5479 } | 5479 } |
| 5480 | 5480 |
| 5481 @override | 5481 @override |
| 5482 bool get isConst => _isConst ?? false; | 5482 bool get isConst => _isConst ??= false; |
| 5483 | 5483 |
| 5484 /** | 5484 /** |
| 5485 * Indicates whether the variable is declared using the `const` keyword. | 5485 * Indicates whether the variable is declared using the `const` keyword. |
| 5486 */ | 5486 */ |
| 5487 void set isConst(bool _value) { | 5487 void set isConst(bool _value) { |
| 5488 assert(!_finished); | 5488 assert(!_finished); |
| 5489 _isConst = _value; | 5489 _isConst = _value; |
| 5490 } | 5490 } |
| 5491 | 5491 |
| 5492 @override | 5492 @override |
| 5493 bool get hasImplicitType => _hasImplicitType ?? false; | 5493 bool get hasImplicitType => _hasImplicitType ??= false; |
| 5494 | 5494 |
| 5495 /** | 5495 /** |
| 5496 * Indicates whether this variable lacks an explicit type declaration. | 5496 * Indicates whether this variable lacks an explicit type declaration. |
| 5497 */ | 5497 */ |
| 5498 void set hasImplicitType(bool _value) { | 5498 void set hasImplicitType(bool _value) { |
| 5499 assert(!_finished); | 5499 assert(!_finished); |
| 5500 _hasImplicitType = _value; | 5500 _hasImplicitType = _value; |
| 5501 } | 5501 } |
| 5502 | 5502 |
| 5503 @override | 5503 @override |
| 5504 int get propagatedTypeSlot => _propagatedTypeSlot ?? 0; | 5504 int get propagatedTypeSlot => _propagatedTypeSlot ??= 0; |
| 5505 | 5505 |
| 5506 /** | 5506 /** |
| 5507 * If this variable is propagable, nonzero slot id identifying which entry in | 5507 * If this variable is propagable, nonzero slot id identifying which entry in |
| 5508 * [LinkedLibrary.types] contains the propagated type for this variable. If | 5508 * [LinkedLibrary.types] contains the propagated type for this variable. If |
| 5509 * there is no matching entry in [LinkedLibrary.types], then this variable's | 5509 * there is no matching entry in [LinkedLibrary.types], then this variable's |
| 5510 * propagated type is the same as its declared type. | 5510 * propagated type is the same as its declared type. |
| 5511 * | 5511 * |
| 5512 * Non-propagable variables have a [propagatedTypeSlot] of zero. | 5512 * Non-propagable variables have a [propagatedTypeSlot] of zero. |
| 5513 */ | 5513 */ |
| 5514 void set propagatedTypeSlot(int _value) { | 5514 void set propagatedTypeSlot(int _value) { |
| (...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5745 "type": type, | 5745 "type": type, |
| 5746 "constExpr": constExpr, | 5746 "constExpr": constExpr, |
| 5747 "isStatic": isStatic, | 5747 "isStatic": isStatic, |
| 5748 "isFinal": isFinal, | 5748 "isFinal": isFinal, |
| 5749 "isConst": isConst, | 5749 "isConst": isConst, |
| 5750 "hasImplicitType": hasImplicitType, | 5750 "hasImplicitType": hasImplicitType, |
| 5751 "propagatedTypeSlot": propagatedTypeSlot, | 5751 "propagatedTypeSlot": propagatedTypeSlot, |
| 5752 }; | 5752 }; |
| 5753 } | 5753 } |
| 5754 | 5754 |
| OLD | NEW |