| 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 'dart:convert' as convert; | 10 import 'dart:convert' as convert; |
| (...skipping 3323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3334 @override | 3334 @override |
| 3335 String toString() => convert.JSON.encode(toJson()); | 3335 String toString() => convert.JSON.encode(toJson()); |
| 3336 } | 3336 } |
| 3337 | 3337 |
| 3338 class LinkedReferenceBuilder extends Object | 3338 class LinkedReferenceBuilder extends Object |
| 3339 with _LinkedReferenceMixin | 3339 with _LinkedReferenceMixin |
| 3340 implements idl.LinkedReference { | 3340 implements idl.LinkedReference { |
| 3341 int _containingReference; | 3341 int _containingReference; |
| 3342 int _dependency; | 3342 int _dependency; |
| 3343 idl.ReferenceKind _kind; | 3343 idl.ReferenceKind _kind; |
| 3344 int _localIndex; | |
| 3345 String _name; | 3344 String _name; |
| 3346 int _numTypeParameters; | 3345 int _numTypeParameters; |
| 3347 int _unit; | 3346 int _unit; |
| 3348 | 3347 |
| 3349 @override | 3348 @override |
| 3350 int get containingReference => _containingReference ??= 0; | 3349 int get containingReference => _containingReference ??= 0; |
| 3351 | 3350 |
| 3352 /** | 3351 /** |
| 3353 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], | 3352 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], |
| 3354 * and the entity being referred to is contained within another entity, index | 3353 * and the entity being referred to is contained within another entity, index |
| (...skipping 30 matching lines...) Expand all Loading... |
| 3385 | 3384 |
| 3386 /** | 3385 /** |
| 3387 * The kind of the entity being referred to. For the pseudo-types `dynamic` | 3386 * The kind of the entity being referred to. For the pseudo-types `dynamic` |
| 3388 * and `void`, the kind is [ReferenceKind.classOrEnum]. | 3387 * and `void`, the kind is [ReferenceKind.classOrEnum]. |
| 3389 */ | 3388 */ |
| 3390 void set kind(idl.ReferenceKind value) { | 3389 void set kind(idl.ReferenceKind value) { |
| 3391 this._kind = value; | 3390 this._kind = value; |
| 3392 } | 3391 } |
| 3393 | 3392 |
| 3394 @override | 3393 @override |
| 3395 int get localIndex => _localIndex ??= 0; | 3394 int get localIndex => |
| 3396 | 3395 throw new UnimplementedError('attempt to access deprecated field'); |
| 3397 /** | |
| 3398 * If [kind] is [ReferenceKind.function] (that is, the entity being referred | |
| 3399 * to is a local function), the index of the function within | |
| 3400 * [UnlinkedExecutable.localFunctions]. Otherwise zero. | |
| 3401 */ | |
| 3402 void set localIndex(int value) { | |
| 3403 assert(value == null || value >= 0); | |
| 3404 this._localIndex = value; | |
| 3405 } | |
| 3406 | 3396 |
| 3407 @override | 3397 @override |
| 3408 String get name => _name ??= ''; | 3398 String get name => _name ??= ''; |
| 3409 | 3399 |
| 3410 /** | 3400 /** |
| 3411 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], | 3401 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], |
| 3412 * name of the entity being referred to. For the pseudo-type `dynamic`, the | 3402 * name of the entity being referred to. For the pseudo-type `dynamic`, the |
| 3413 * string is "dynamic". For the pseudo-type `void`, the string is "void". | 3403 * string is "dynamic". For the pseudo-type `void`, the string is "void". |
| 3414 */ | 3404 */ |
| 3415 void set name(String value) { | 3405 void set name(String value) { |
| (...skipping 27 matching lines...) Expand all Loading... |
| 3443 */ | 3433 */ |
| 3444 void set unit(int value) { | 3434 void set unit(int value) { |
| 3445 assert(value == null || value >= 0); | 3435 assert(value == null || value >= 0); |
| 3446 this._unit = value; | 3436 this._unit = value; |
| 3447 } | 3437 } |
| 3448 | 3438 |
| 3449 LinkedReferenceBuilder( | 3439 LinkedReferenceBuilder( |
| 3450 {int containingReference, | 3440 {int containingReference, |
| 3451 int dependency, | 3441 int dependency, |
| 3452 idl.ReferenceKind kind, | 3442 idl.ReferenceKind kind, |
| 3453 int localIndex, | |
| 3454 String name, | 3443 String name, |
| 3455 int numTypeParameters, | 3444 int numTypeParameters, |
| 3456 int unit}) | 3445 int unit}) |
| 3457 : _containingReference = containingReference, | 3446 : _containingReference = containingReference, |
| 3458 _dependency = dependency, | 3447 _dependency = dependency, |
| 3459 _kind = kind, | 3448 _kind = kind, |
| 3460 _localIndex = localIndex, | |
| 3461 _name = name, | 3449 _name = name, |
| 3462 _numTypeParameters = numTypeParameters, | 3450 _numTypeParameters = numTypeParameters, |
| 3463 _unit = unit; | 3451 _unit = unit; |
| 3464 | 3452 |
| 3465 /** | 3453 /** |
| 3466 * Flush [informative] data recursively. | 3454 * Flush [informative] data recursively. |
| 3467 */ | 3455 */ |
| 3468 void flushInformative() {} | 3456 void flushInformative() {} |
| 3469 | 3457 |
| 3470 /** | 3458 /** |
| 3471 * Accumulate non-[informative] data into [signature]. | 3459 * Accumulate non-[informative] data into [signature]. |
| 3472 */ | 3460 */ |
| 3473 void collectApiSignature(api_sig.ApiSignature signature) { | 3461 void collectApiSignature(api_sig.ApiSignature signature) { |
| 3474 signature.addInt(this._unit ?? 0); | 3462 signature.addInt(this._unit ?? 0); |
| 3475 signature.addInt(this._dependency ?? 0); | 3463 signature.addInt(this._dependency ?? 0); |
| 3476 signature.addInt(this._kind == null ? 0 : this._kind.index); | 3464 signature.addInt(this._kind == null ? 0 : this._kind.index); |
| 3477 signature.addString(this._name ?? ''); | 3465 signature.addString(this._name ?? ''); |
| 3478 signature.addInt(this._numTypeParameters ?? 0); | 3466 signature.addInt(this._numTypeParameters ?? 0); |
| 3479 signature.addInt(this._containingReference ?? 0); | 3467 signature.addInt(this._containingReference ?? 0); |
| 3480 signature.addInt(this._localIndex ?? 0); | |
| 3481 } | 3468 } |
| 3482 | 3469 |
| 3483 fb.Offset finish(fb.Builder fbBuilder) { | 3470 fb.Offset finish(fb.Builder fbBuilder) { |
| 3484 fb.Offset offset_name; | 3471 fb.Offset offset_name; |
| 3485 if (_name != null) { | 3472 if (_name != null) { |
| 3486 offset_name = fbBuilder.writeString(_name); | 3473 offset_name = fbBuilder.writeString(_name); |
| 3487 } | 3474 } |
| 3488 fbBuilder.startTable(); | 3475 fbBuilder.startTable(); |
| 3489 if (_containingReference != null && _containingReference != 0) { | 3476 if (_containingReference != null && _containingReference != 0) { |
| 3490 fbBuilder.addUint32(5, _containingReference); | 3477 fbBuilder.addUint32(5, _containingReference); |
| 3491 } | 3478 } |
| 3492 if (_dependency != null && _dependency != 0) { | 3479 if (_dependency != null && _dependency != 0) { |
| 3493 fbBuilder.addUint32(1, _dependency); | 3480 fbBuilder.addUint32(1, _dependency); |
| 3494 } | 3481 } |
| 3495 if (_kind != null && _kind != idl.ReferenceKind.classOrEnum) { | 3482 if (_kind != null && _kind != idl.ReferenceKind.classOrEnum) { |
| 3496 fbBuilder.addUint8(2, _kind.index); | 3483 fbBuilder.addUint8(2, _kind.index); |
| 3497 } | 3484 } |
| 3498 if (_localIndex != null && _localIndex != 0) { | |
| 3499 fbBuilder.addUint32(6, _localIndex); | |
| 3500 } | |
| 3501 if (offset_name != null) { | 3485 if (offset_name != null) { |
| 3502 fbBuilder.addOffset(3, offset_name); | 3486 fbBuilder.addOffset(3, offset_name); |
| 3503 } | 3487 } |
| 3504 if (_numTypeParameters != null && _numTypeParameters != 0) { | 3488 if (_numTypeParameters != null && _numTypeParameters != 0) { |
| 3505 fbBuilder.addUint32(4, _numTypeParameters); | 3489 fbBuilder.addUint32(4, _numTypeParameters); |
| 3506 } | 3490 } |
| 3507 if (_unit != null && _unit != 0) { | 3491 if (_unit != null && _unit != 0) { |
| 3508 fbBuilder.addUint32(0, _unit); | 3492 fbBuilder.addUint32(0, _unit); |
| 3509 } | 3493 } |
| 3510 return fbBuilder.endTable(); | 3494 return fbBuilder.endTable(); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 3523 with _LinkedReferenceMixin | 3507 with _LinkedReferenceMixin |
| 3524 implements idl.LinkedReference { | 3508 implements idl.LinkedReference { |
| 3525 final fb.BufferContext _bc; | 3509 final fb.BufferContext _bc; |
| 3526 final int _bcOffset; | 3510 final int _bcOffset; |
| 3527 | 3511 |
| 3528 _LinkedReferenceImpl(this._bc, this._bcOffset); | 3512 _LinkedReferenceImpl(this._bc, this._bcOffset); |
| 3529 | 3513 |
| 3530 int _containingReference; | 3514 int _containingReference; |
| 3531 int _dependency; | 3515 int _dependency; |
| 3532 idl.ReferenceKind _kind; | 3516 idl.ReferenceKind _kind; |
| 3533 int _localIndex; | |
| 3534 String _name; | 3517 String _name; |
| 3535 int _numTypeParameters; | 3518 int _numTypeParameters; |
| 3536 int _unit; | 3519 int _unit; |
| 3537 | 3520 |
| 3538 @override | 3521 @override |
| 3539 int get containingReference { | 3522 int get containingReference { |
| 3540 _containingReference ??= | 3523 _containingReference ??= |
| 3541 const fb.Uint32Reader().vTableGet(_bc, _bcOffset, 5, 0); | 3524 const fb.Uint32Reader().vTableGet(_bc, _bcOffset, 5, 0); |
| 3542 return _containingReference; | 3525 return _containingReference; |
| 3543 } | 3526 } |
| 3544 | 3527 |
| 3545 @override | 3528 @override |
| 3546 int get dependency { | 3529 int get dependency { |
| 3547 _dependency ??= const fb.Uint32Reader().vTableGet(_bc, _bcOffset, 1, 0); | 3530 _dependency ??= const fb.Uint32Reader().vTableGet(_bc, _bcOffset, 1, 0); |
| 3548 return _dependency; | 3531 return _dependency; |
| 3549 } | 3532 } |
| 3550 | 3533 |
| 3551 @override | 3534 @override |
| 3552 idl.ReferenceKind get kind { | 3535 idl.ReferenceKind get kind { |
| 3553 _kind ??= const _ReferenceKindReader() | 3536 _kind ??= const _ReferenceKindReader() |
| 3554 .vTableGet(_bc, _bcOffset, 2, idl.ReferenceKind.classOrEnum); | 3537 .vTableGet(_bc, _bcOffset, 2, idl.ReferenceKind.classOrEnum); |
| 3555 return _kind; | 3538 return _kind; |
| 3556 } | 3539 } |
| 3557 | 3540 |
| 3558 @override | 3541 @override |
| 3559 int get localIndex { | 3542 int get localIndex => |
| 3560 _localIndex ??= const fb.Uint32Reader().vTableGet(_bc, _bcOffset, 6, 0); | 3543 throw new UnimplementedError('attempt to access deprecated field'); |
| 3561 return _localIndex; | |
| 3562 } | |
| 3563 | 3544 |
| 3564 @override | 3545 @override |
| 3565 String get name { | 3546 String get name { |
| 3566 _name ??= const fb.StringReader().vTableGet(_bc, _bcOffset, 3, ''); | 3547 _name ??= const fb.StringReader().vTableGet(_bc, _bcOffset, 3, ''); |
| 3567 return _name; | 3548 return _name; |
| 3568 } | 3549 } |
| 3569 | 3550 |
| 3570 @override | 3551 @override |
| 3571 int get numTypeParameters { | 3552 int get numTypeParameters { |
| 3572 _numTypeParameters ??= | 3553 _numTypeParameters ??= |
| (...skipping 10 matching lines...) Expand all Loading... |
| 3583 | 3564 |
| 3584 abstract class _LinkedReferenceMixin implements idl.LinkedReference { | 3565 abstract class _LinkedReferenceMixin implements idl.LinkedReference { |
| 3585 @override | 3566 @override |
| 3586 Map<String, Object> toJson() { | 3567 Map<String, Object> toJson() { |
| 3587 Map<String, Object> _result = <String, Object>{}; | 3568 Map<String, Object> _result = <String, Object>{}; |
| 3588 if (containingReference != 0) | 3569 if (containingReference != 0) |
| 3589 _result["containingReference"] = containingReference; | 3570 _result["containingReference"] = containingReference; |
| 3590 if (dependency != 0) _result["dependency"] = dependency; | 3571 if (dependency != 0) _result["dependency"] = dependency; |
| 3591 if (kind != idl.ReferenceKind.classOrEnum) | 3572 if (kind != idl.ReferenceKind.classOrEnum) |
| 3592 _result["kind"] = kind.toString().split('.')[1]; | 3573 _result["kind"] = kind.toString().split('.')[1]; |
| 3593 if (localIndex != 0) _result["localIndex"] = localIndex; | |
| 3594 if (name != '') _result["name"] = name; | 3574 if (name != '') _result["name"] = name; |
| 3595 if (numTypeParameters != 0) | 3575 if (numTypeParameters != 0) |
| 3596 _result["numTypeParameters"] = numTypeParameters; | 3576 _result["numTypeParameters"] = numTypeParameters; |
| 3597 if (unit != 0) _result["unit"] = unit; | 3577 if (unit != 0) _result["unit"] = unit; |
| 3598 return _result; | 3578 return _result; |
| 3599 } | 3579 } |
| 3600 | 3580 |
| 3601 @override | 3581 @override |
| 3602 Map<String, Object> toMap() => { | 3582 Map<String, Object> toMap() => { |
| 3603 "containingReference": containingReference, | 3583 "containingReference": containingReference, |
| 3604 "dependency": dependency, | 3584 "dependency": dependency, |
| 3605 "kind": kind, | 3585 "kind": kind, |
| 3606 "localIndex": localIndex, | |
| 3607 "name": name, | 3586 "name": name, |
| 3608 "numTypeParameters": numTypeParameters, | 3587 "numTypeParameters": numTypeParameters, |
| 3609 "unit": unit, | 3588 "unit": unit, |
| 3610 }; | 3589 }; |
| 3611 | 3590 |
| 3612 @override | 3591 @override |
| 3613 String toString() => convert.JSON.encode(toJson()); | 3592 String toString() => convert.JSON.encode(toJson()); |
| 3614 } | 3593 } |
| 3615 | 3594 |
| 3616 class LinkedUnitBuilder extends Object | 3595 class LinkedUnitBuilder extends Object |
| (...skipping 9058 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 12675 "nameOffset": nameOffset, | 12654 "nameOffset": nameOffset, |
| 12676 "propagatedTypeSlot": propagatedTypeSlot, | 12655 "propagatedTypeSlot": propagatedTypeSlot, |
| 12677 "type": type, | 12656 "type": type, |
| 12678 "visibleLength": visibleLength, | 12657 "visibleLength": visibleLength, |
| 12679 "visibleOffset": visibleOffset, | 12658 "visibleOffset": visibleOffset, |
| 12680 }; | 12659 }; |
| 12681 | 12660 |
| 12682 @override | 12661 @override |
| 12683 String toString() => convert.JSON.encode(toJson()); | 12662 String toString() => convert.JSON.encode(toJson()); |
| 12684 } | 12663 } |
| OLD | NEW |