1{ 2 "type": "Program", 3 "statements": [ 4 { 5 "type": "ClassDeclaration", 6 "definition": { 7 "id": { 8 "type": "Identifier", 9 "name": "A", 10 "decorators": [], 11 "loc": { 12 "start": { 13 "line": 16, 14 "column": 7, 15 "program": "test-private-field.js" 16 }, 17 "end": { 18 "line": 16, 19 "column": 8, 20 "program": "test-private-field.js" 21 } 22 } 23 }, 24 "superClass": null, 25 "implements": [], 26 "constructor": { 27 "type": "MethodDefinition", 28 "key": { 29 "type": "Identifier", 30 "name": "constructor", 31 "decorators": [], 32 "loc": { 33 "start": { 34 "line": 16, 35 "column": 10, 36 "program": "test-private-field.js" 37 }, 38 "end": { 39 "line": 16, 40 "column": 10, 41 "program": "test-private-field.js" 42 } 43 } 44 }, 45 "kind": "constructor", 46 "static": false, 47 "optional": false, 48 "computed": false, 49 "value": { 50 "type": "FunctionExpression", 51 "function": { 52 "type": "ScriptFunction", 53 "id": null, 54 "generator": false, 55 "async": false, 56 "expression": false, 57 "params": [], 58 "body": { 59 "type": "BlockStatement", 60 "statements": [], 61 "loc": { 62 "start": { 63 "line": 16, 64 "column": 10, 65 "program": "test-private-field.js" 66 }, 67 "end": { 68 "line": 16, 69 "column": 10, 70 "program": "test-private-field.js" 71 } 72 } 73 }, 74 "loc": { 75 "start": { 76 "line": 16, 77 "column": 10, 78 "program": "test-private-field.js" 79 }, 80 "end": { 81 "line": 16, 82 "column": 10, 83 "program": "test-private-field.js" 84 } 85 } 86 }, 87 "loc": { 88 "start": { 89 "line": 16, 90 "column": 10, 91 "program": "test-private-field.js" 92 }, 93 "end": { 94 "line": 16, 95 "column": 10, 96 "program": "test-private-field.js" 97 } 98 } 99 }, 100 "overloads": [], 101 "decorators": [], 102 "loc": { 103 "start": { 104 "line": 1, 105 "column": 1, 106 "program": null 107 }, 108 "end": { 109 "line": 1, 110 "column": 1, 111 "program": null 112 } 113 } 114 }, 115 "body": [ 116 { 117 "type": "ClassProperty", 118 "key": { 119 "type": "PrivateIdentifier", 120 "name": "a", 121 "decorators": [], 122 "loc": { 123 "start": { 124 "line": 17, 125 "column": 6, 126 "program": "test-private-field.js" 127 }, 128 "end": { 129 "line": 17, 130 "column": 7, 131 "program": "test-private-field.js" 132 } 133 } 134 }, 135 "static": false, 136 "readonly": false, 137 "declare": false, 138 "optional": false, 139 "computed": false, 140 "definite": false, 141 "decorators": [], 142 "loc": { 143 "start": { 144 "line": 17, 145 "column": 5, 146 "program": "test-private-field.js" 147 }, 148 "end": { 149 "line": 17, 150 "column": 7, 151 "program": "test-private-field.js" 152 } 153 } 154 }, 155 { 156 "type": "MethodDefinition", 157 "key": { 158 "type": "PrivateIdentifier", 159 "name": "b", 160 "decorators": [], 161 "loc": { 162 "start": { 163 "line": 18, 164 "column": 13, 165 "program": "test-private-field.js" 166 }, 167 "end": { 168 "line": 18, 169 "column": 14, 170 "program": "test-private-field.js" 171 } 172 } 173 }, 174 "kind": "method", 175 "static": true, 176 "optional": false, 177 "computed": false, 178 "value": { 179 "type": "FunctionExpression", 180 "function": { 181 "type": "ScriptFunction", 182 "id": null, 183 "generator": false, 184 "async": false, 185 "expression": false, 186 "params": [], 187 "body": { 188 "type": "BlockStatement", 189 "statements": [], 190 "loc": { 191 "start": { 192 "line": 18, 193 "column": 17, 194 "program": "test-private-field.js" 195 }, 196 "end": { 197 "line": 18, 198 "column": 20, 199 "program": "test-private-field.js" 200 } 201 } 202 }, 203 "loc": { 204 "start": { 205 "line": 18, 206 "column": 14, 207 "program": "test-private-field.js" 208 }, 209 "end": { 210 "line": 18, 211 "column": 20, 212 "program": "test-private-field.js" 213 } 214 } 215 }, 216 "loc": { 217 "start": { 218 "line": 18, 219 "column": 14, 220 "program": "test-private-field.js" 221 }, 222 "end": { 223 "line": 18, 224 "column": 20, 225 "program": "test-private-field.js" 226 } 227 } 228 }, 229 "overloads": [], 230 "decorators": [], 231 "loc": { 232 "start": { 233 "line": 18, 234 "column": 5, 235 "program": "test-private-field.js" 236 }, 237 "end": { 238 "line": 18, 239 "column": 20, 240 "program": "test-private-field.js" 241 } 242 } 243 }, 244 { 245 "type": "MethodDefinition", 246 "key": { 247 "type": "PrivateIdentifier", 248 "name": "t", 249 "decorators": [], 250 "loc": { 251 "start": { 252 "line": 19, 253 "column": 13, 254 "program": "test-private-field.js" 255 }, 256 "end": { 257 "line": 19, 258 "column": 14, 259 "program": "test-private-field.js" 260 } 261 } 262 }, 263 "kind": "method", 264 "static": false, 265 "optional": false, 266 "computed": false, 267 "value": { 268 "type": "FunctionExpression", 269 "function": { 270 "type": "ScriptFunction", 271 "id": null, 272 "generator": true, 273 "async": true, 274 "expression": false, 275 "params": [], 276 "body": { 277 "type": "BlockStatement", 278 "statements": [], 279 "loc": { 280 "start": { 281 "line": 19, 282 "column": 17, 283 "program": "test-private-field.js" 284 }, 285 "end": { 286 "line": 19, 287 "column": 20, 288 "program": "test-private-field.js" 289 } 290 } 291 }, 292 "loc": { 293 "start": { 294 "line": 19, 295 "column": 14, 296 "program": "test-private-field.js" 297 }, 298 "end": { 299 "line": 19, 300 "column": 20, 301 "program": "test-private-field.js" 302 } 303 } 304 }, 305 "loc": { 306 "start": { 307 "line": 19, 308 "column": 14, 309 "program": "test-private-field.js" 310 }, 311 "end": { 312 "line": 19, 313 "column": 20, 314 "program": "test-private-field.js" 315 } 316 } 317 }, 318 "overloads": [], 319 "decorators": [], 320 "loc": { 321 "start": { 322 "line": 19, 323 "column": 5, 324 "program": "test-private-field.js" 325 }, 326 "end": { 327 "line": 19, 328 "column": 20, 329 "program": "test-private-field.js" 330 } 331 } 332 }, 333 { 334 "type": "MethodDefinition", 335 "key": { 336 "type": "PrivateIdentifier", 337 "name": "z", 338 "decorators": [], 339 "loc": { 340 "start": { 341 "line": 20, 342 "column": 17, 343 "program": "test-private-field.js" 344 }, 345 "end": { 346 "line": 20, 347 "column": 18, 348 "program": "test-private-field.js" 349 } 350 } 351 }, 352 "kind": "get", 353 "static": true, 354 "optional": false, 355 "computed": false, 356 "value": { 357 "type": "FunctionExpression", 358 "function": { 359 "type": "ScriptFunction", 360 "id": null, 361 "generator": false, 362 "async": false, 363 "expression": false, 364 "params": [], 365 "body": { 366 "type": "BlockStatement", 367 "statements": [], 368 "loc": { 369 "start": { 370 "line": 20, 371 "column": 21, 372 "program": "test-private-field.js" 373 }, 374 "end": { 375 "line": 20, 376 "column": 24, 377 "program": "test-private-field.js" 378 } 379 } 380 }, 381 "loc": { 382 "start": { 383 "line": 20, 384 "column": 18, 385 "program": "test-private-field.js" 386 }, 387 "end": { 388 "line": 20, 389 "column": 24, 390 "program": "test-private-field.js" 391 } 392 } 393 }, 394 "loc": { 395 "start": { 396 "line": 20, 397 "column": 18, 398 "program": "test-private-field.js" 399 }, 400 "end": { 401 "line": 20, 402 "column": 24, 403 "program": "test-private-field.js" 404 } 405 } 406 }, 407 "overloads": [], 408 "decorators": [], 409 "loc": { 410 "start": { 411 "line": 20, 412 "column": 5, 413 "program": "test-private-field.js" 414 }, 415 "end": { 416 "line": 20, 417 "column": 24, 418 "program": "test-private-field.js" 419 } 420 } 421 }, 422 { 423 "type": "MethodDefinition", 424 "key": { 425 "type": "PrivateIdentifier", 426 "name": "z", 427 "decorators": [], 428 "loc": { 429 "start": { 430 "line": 21, 431 "column": 17, 432 "program": "test-private-field.js" 433 }, 434 "end": { 435 "line": 21, 436 "column": 18, 437 "program": "test-private-field.js" 438 } 439 } 440 }, 441 "kind": "set", 442 "static": true, 443 "optional": false, 444 "computed": false, 445 "value": { 446 "type": "FunctionExpression", 447 "function": { 448 "type": "ScriptFunction", 449 "id": null, 450 "generator": false, 451 "async": false, 452 "expression": false, 453 "params": [ 454 { 455 "type": "Identifier", 456 "name": "t", 457 "decorators": [], 458 "loc": { 459 "start": { 460 "line": 21, 461 "column": 19, 462 "program": "test-private-field.js" 463 }, 464 "end": { 465 "line": 21, 466 "column": 20, 467 "program": "test-private-field.js" 468 } 469 } 470 } 471 ], 472 "body": { 473 "type": "BlockStatement", 474 "statements": [], 475 "loc": { 476 "start": { 477 "line": 21, 478 "column": 22, 479 "program": "test-private-field.js" 480 }, 481 "end": { 482 "line": 21, 483 "column": 25, 484 "program": "test-private-field.js" 485 } 486 } 487 }, 488 "loc": { 489 "start": { 490 "line": 21, 491 "column": 18, 492 "program": "test-private-field.js" 493 }, 494 "end": { 495 "line": 21, 496 "column": 25, 497 "program": "test-private-field.js" 498 } 499 } 500 }, 501 "loc": { 502 "start": { 503 "line": 21, 504 "column": 18, 505 "program": "test-private-field.js" 506 }, 507 "end": { 508 "line": 21, 509 "column": 25, 510 "program": "test-private-field.js" 511 } 512 } 513 }, 514 "overloads": [], 515 "decorators": [], 516 "loc": { 517 "start": { 518 "line": 21, 519 "column": 5, 520 "program": "test-private-field.js" 521 }, 522 "end": { 523 "line": 21, 524 "column": 25, 525 "program": "test-private-field.js" 526 } 527 } 528 }, 529 { 530 "type": "ClassProperty", 531 "key": { 532 "type": "Identifier", 533 "name": "u", 534 "decorators": [], 535 "loc": { 536 "start": { 537 "line": 22, 538 "column": 5, 539 "program": "test-private-field.js" 540 }, 541 "end": { 542 "line": 22, 543 "column": 6, 544 "program": "test-private-field.js" 545 } 546 } 547 }, 548 "value": { 549 "type": "ClassExpression", 550 "definition": { 551 "id": null, 552 "superClass": null, 553 "implements": [], 554 "constructor": { 555 "type": "MethodDefinition", 556 "key": { 557 "type": "Identifier", 558 "name": "constructor", 559 "decorators": [], 560 "loc": { 561 "start": { 562 "line": 22, 563 "column": 16, 564 "program": "test-private-field.js" 565 }, 566 "end": { 567 "line": 22, 568 "column": 16, 569 "program": "test-private-field.js" 570 } 571 } 572 }, 573 "kind": "constructor", 574 "static": false, 575 "optional": false, 576 "computed": false, 577 "value": { 578 "type": "FunctionExpression", 579 "function": { 580 "type": "ScriptFunction", 581 "id": null, 582 "generator": false, 583 "async": false, 584 "expression": false, 585 "params": [], 586 "body": { 587 "type": "BlockStatement", 588 "statements": [], 589 "loc": { 590 "start": { 591 "line": 22, 592 "column": 16, 593 "program": "test-private-field.js" 594 }, 595 "end": { 596 "line": 22, 597 "column": 16, 598 "program": "test-private-field.js" 599 } 600 } 601 }, 602 "loc": { 603 "start": { 604 "line": 22, 605 "column": 16, 606 "program": "test-private-field.js" 607 }, 608 "end": { 609 "line": 22, 610 "column": 16, 611 "program": "test-private-field.js" 612 } 613 } 614 }, 615 "loc": { 616 "start": { 617 "line": 22, 618 "column": 16, 619 "program": "test-private-field.js" 620 }, 621 "end": { 622 "line": 22, 623 "column": 16, 624 "program": "test-private-field.js" 625 } 626 } 627 }, 628 "overloads": [], 629 "decorators": [], 630 "loc": { 631 "start": { 632 "line": 1, 633 "column": 1, 634 "program": null 635 }, 636 "end": { 637 "line": 1, 638 "column": 1, 639 "program": null 640 } 641 } 642 }, 643 "body": [ 644 { 645 "type": "MethodDefinition", 646 "key": { 647 "type": "Identifier", 648 "name": "e", 649 "decorators": [], 650 "loc": { 651 "start": { 652 "line": 23, 653 "column": 9, 654 "program": "test-private-field.js" 655 }, 656 "end": { 657 "line": 23, 658 "column": 10, 659 "program": "test-private-field.js" 660 } 661 } 662 }, 663 "kind": "method", 664 "static": false, 665 "optional": false, 666 "computed": false, 667 "value": { 668 "type": "FunctionExpression", 669 "function": { 670 "type": "ScriptFunction", 671 "id": null, 672 "generator": false, 673 "async": false, 674 "expression": false, 675 "params": [], 676 "body": { 677 "type": "BlockStatement", 678 "statements": [ 679 { 680 "type": "IfStatement", 681 "test": { 682 "type": "BinaryExpression", 683 "operator": "in", 684 "left": { 685 "type": "PrivateIdentifier", 686 "name": "a", 687 "decorators": [], 688 "loc": { 689 "start": { 690 "line": 1, 691 "column": 1, 692 "program": null 693 }, 694 "end": { 695 "line": 1, 696 "column": 1, 697 "program": null 698 } 699 } 700 }, 701 "right": { 702 "type": "ThisExpression", 703 "loc": { 704 "start": { 705 "line": 24, 706 "column": 23, 707 "program": "test-private-field.js" 708 }, 709 "end": { 710 "line": 24, 711 "column": 27, 712 "program": "test-private-field.js" 713 } 714 } 715 }, 716 "loc": { 717 "start": { 718 "line": 1, 719 "column": 1, 720 "program": null 721 }, 722 "end": { 723 "line": 24, 724 "column": 27, 725 "program": "test-private-field.js" 726 } 727 } 728 }, 729 "consequent": { 730 "type": "BlockStatement", 731 "statements": [ 732 { 733 "type": "ExpressionStatement", 734 "expression": { 735 "type": "AssignmentExpression", 736 "operator": "=", 737 "left": { 738 "type": "MemberExpression", 739 "object": { 740 "type": "ThisExpression", 741 "loc": { 742 "start": { 743 "line": 25, 744 "column": 17, 745 "program": "test-private-field.js" 746 }, 747 "end": { 748 "line": 25, 749 "column": 21, 750 "program": "test-private-field.js" 751 } 752 } 753 }, 754 "property": { 755 "type": "PrivateIdentifier", 756 "name": "a", 757 "decorators": [], 758 "loc": { 759 "start": { 760 "line": 25, 761 "column": 22, 762 "program": "test-private-field.js" 763 }, 764 "end": { 765 "line": 25, 766 "column": 24, 767 "program": "test-private-field.js" 768 } 769 } 770 }, 771 "computed": false, 772 "optional": false, 773 "loc": { 774 "start": { 775 "line": 25, 776 "column": 17, 777 "program": "test-private-field.js" 778 }, 779 "end": { 780 "line": 25, 781 "column": 24, 782 "program": "test-private-field.js" 783 } 784 } 785 }, 786 "right": { 787 "type": "NumberLiteral", 788 "value": 12, 789 "loc": { 790 "start": { 791 "line": 25, 792 "column": 27, 793 "program": "test-private-field.js" 794 }, 795 "end": { 796 "line": 25, 797 "column": 29, 798 "program": "test-private-field.js" 799 } 800 } 801 }, 802 "loc": { 803 "start": { 804 "line": 25, 805 "column": 17, 806 "program": "test-private-field.js" 807 }, 808 "end": { 809 "line": 25, 810 "column": 29, 811 "program": "test-private-field.js" 812 } 813 } 814 }, 815 "loc": { 816 "start": { 817 "line": 25, 818 "column": 17, 819 "program": "test-private-field.js" 820 }, 821 "end": { 822 "line": 25, 823 "column": 30, 824 "program": "test-private-field.js" 825 } 826 } 827 }, 828 { 829 "type": "ExpressionStatement", 830 "expression": { 831 "type": "CallExpression", 832 "callee": { 833 "type": "MemberExpression", 834 "object": { 835 "type": "ThisExpression", 836 "loc": { 837 "start": { 838 "line": 26, 839 "column": 17, 840 "program": "test-private-field.js" 841 }, 842 "end": { 843 "line": 26, 844 "column": 21, 845 "program": "test-private-field.js" 846 } 847 } 848 }, 849 "property": { 850 "type": "PrivateIdentifier", 851 "name": "t", 852 "decorators": [], 853 "loc": { 854 "start": { 855 "line": 26, 856 "column": 22, 857 "program": "test-private-field.js" 858 }, 859 "end": { 860 "line": 26, 861 "column": 24, 862 "program": "test-private-field.js" 863 } 864 } 865 }, 866 "computed": false, 867 "optional": false, 868 "loc": { 869 "start": { 870 "line": 26, 871 "column": 17, 872 "program": "test-private-field.js" 873 }, 874 "end": { 875 "line": 26, 876 "column": 24, 877 "program": "test-private-field.js" 878 } 879 } 880 }, 881 "arguments": [], 882 "optional": false, 883 "loc": { 884 "start": { 885 "line": 26, 886 "column": 17, 887 "program": "test-private-field.js" 888 }, 889 "end": { 890 "line": 26, 891 "column": 26, 892 "program": "test-private-field.js" 893 } 894 } 895 }, 896 "loc": { 897 "start": { 898 "line": 26, 899 "column": 17, 900 "program": "test-private-field.js" 901 }, 902 "end": { 903 "line": 26, 904 "column": 27, 905 "program": "test-private-field.js" 906 } 907 } 908 } 909 ], 910 "loc": { 911 "start": { 912 "line": 24, 913 "column": 29, 914 "program": "test-private-field.js" 915 }, 916 "end": { 917 "line": 27, 918 "column": 14, 919 "program": "test-private-field.js" 920 } 921 } 922 }, 923 "alternate": null, 924 "loc": { 925 "start": { 926 "line": 24, 927 "column": 13, 928 "program": "test-private-field.js" 929 }, 930 "end": { 931 "line": 27, 932 "column": 14, 933 "program": "test-private-field.js" 934 } 935 } 936 } 937 ], 938 "loc": { 939 "start": { 940 "line": 23, 941 "column": 13, 942 "program": "test-private-field.js" 943 }, 944 "end": { 945 "line": 28, 946 "column": 10, 947 "program": "test-private-field.js" 948 } 949 } 950 }, 951 "loc": { 952 "start": { 953 "line": 23, 954 "column": 10, 955 "program": "test-private-field.js" 956 }, 957 "end": { 958 "line": 28, 959 "column": 10, 960 "program": "test-private-field.js" 961 } 962 } 963 }, 964 "loc": { 965 "start": { 966 "line": 23, 967 "column": 10, 968 "program": "test-private-field.js" 969 }, 970 "end": { 971 "line": 28, 972 "column": 10, 973 "program": "test-private-field.js" 974 } 975 } 976 }, 977 "overloads": [], 978 "decorators": [], 979 "loc": { 980 "start": { 981 "line": 23, 982 "column": 9, 983 "program": "test-private-field.js" 984 }, 985 "end": { 986 "line": 28, 987 "column": 10, 988 "program": "test-private-field.js" 989 } 990 } 991 }, 992 { 993 "type": "MethodDefinition", 994 "key": { 995 "type": "PrivateIdentifier", 996 "name": "t", 997 "decorators": [], 998 "loc": { 999 "start": { 1000 "line": 29, 1001 "column": 10, 1002 "program": "test-private-field.js" 1003 }, 1004 "end": { 1005 "line": 29, 1006 "column": 11, 1007 "program": "test-private-field.js" 1008 } 1009 } 1010 }, 1011 "kind": "method", 1012 "static": false, 1013 "optional": false, 1014 "computed": false, 1015 "value": { 1016 "type": "FunctionExpression", 1017 "function": { 1018 "type": "ScriptFunction", 1019 "id": null, 1020 "generator": false, 1021 "async": false, 1022 "expression": false, 1023 "params": [], 1024 "body": { 1025 "type": "BlockStatement", 1026 "statements": [], 1027 "loc": { 1028 "start": { 1029 "line": 29, 1030 "column": 14, 1031 "program": "test-private-field.js" 1032 }, 1033 "end": { 1034 "line": 29, 1035 "column": 17, 1036 "program": "test-private-field.js" 1037 } 1038 } 1039 }, 1040 "loc": { 1041 "start": { 1042 "line": 29, 1043 "column": 11, 1044 "program": "test-private-field.js" 1045 }, 1046 "end": { 1047 "line": 29, 1048 "column": 17, 1049 "program": "test-private-field.js" 1050 } 1051 } 1052 }, 1053 "loc": { 1054 "start": { 1055 "line": 29, 1056 "column": 11, 1057 "program": "test-private-field.js" 1058 }, 1059 "end": { 1060 "line": 29, 1061 "column": 17, 1062 "program": "test-private-field.js" 1063 } 1064 } 1065 }, 1066 "overloads": [], 1067 "decorators": [], 1068 "loc": { 1069 "start": { 1070 "line": 29, 1071 "column": 9, 1072 "program": "test-private-field.js" 1073 }, 1074 "end": { 1075 "line": 29, 1076 "column": 17, 1077 "program": "test-private-field.js" 1078 } 1079 } 1080 } 1081 ], 1082 "loc": { 1083 "start": { 1084 "line": 22, 1085 "column": 15, 1086 "program": "test-private-field.js" 1087 }, 1088 "end": { 1089 "line": 31, 1090 "column": 2, 1091 "program": "test-private-field.js" 1092 } 1093 } 1094 }, 1095 "loc": { 1096 "start": { 1097 "line": 22, 1098 "column": 9, 1099 "program": "test-private-field.js" 1100 }, 1101 "end": { 1102 "line": 31, 1103 "column": 2, 1104 "program": "test-private-field.js" 1105 } 1106 } 1107 }, 1108 "static": false, 1109 "readonly": false, 1110 "declare": false, 1111 "optional": false, 1112 "computed": false, 1113 "definite": false, 1114 "decorators": [], 1115 "loc": { 1116 "start": { 1117 "line": 22, 1118 "column": 5, 1119 "program": "test-private-field.js" 1120 }, 1121 "end": { 1122 "line": 31, 1123 "column": 2, 1124 "program": "test-private-field.js" 1125 } 1126 } 1127 } 1128 ], 1129 "loc": { 1130 "start": { 1131 "line": 16, 1132 "column": 9, 1133 "program": "test-private-field.js" 1134 }, 1135 "end": { 1136 "line": 32, 1137 "column": 1, 1138 "program": "test-private-field.js" 1139 } 1140 } 1141 }, 1142 "loc": { 1143 "start": { 1144 "line": 16, 1145 "column": 1, 1146 "program": "test-private-field.js" 1147 }, 1148 "end": { 1149 "line": 32, 1150 "column": 1, 1151 "program": "test-private-field.js" 1152 } 1153 } 1154 } 1155 ], 1156 "loc": { 1157 "start": { 1158 "line": 1, 1159 "column": 1, 1160 "program": "test-private-field.js" 1161 }, 1162 "end": { 1163 "line": 32, 1164 "column": 1, 1165 "program": "test-private-field.js" 1166 } 1167 } 1168} 1169