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