1TypeError: Right-hand side of instanceof expression must represent a type. [instanceof_dyndecl_jsvalue.sts:23:12]
2{
3  "type": "Program",
4  "statements": [
5    {
6      "type": "ImportDeclaration",
7      "source": {
8        "type": "StringLiteral",
9        "value": "dynamic_import_tests/modules/instanceof",
10        "loc": {
11          "start": {
12            "line": 20,
13            "column": 27
14          },
15          "end": {
16            "line": 20,
17            "column": 68
18          }
19        }
20      },
21      "specifiers": [
22        {
23          "type": "ImportSpecifier",
24          "local": {
25            "type": "Identifier",
26            "name": "ADeclared",
27            "decorators": [],
28            "loc": {
29              "start": {
30                "line": 20,
31                "column": 10
32              },
33              "end": {
34                "line": 20,
35                "column": 19
36              }
37            }
38          },
39          "imported": {
40            "type": "Identifier",
41            "name": "ADeclared",
42            "decorators": [],
43            "loc": {
44              "start": {
45                "line": 20,
46                "column": 10
47              },
48              "end": {
49                "line": 20,
50                "column": 19
51              }
52            }
53          },
54          "loc": {
55            "start": {
56              "line": 20,
57              "column": 10
58            },
59            "end": {
60              "line": 20,
61              "column": 19
62            }
63          }
64        }
65      ],
66      "loc": {
67        "start": {
68          "line": 20,
69          "column": 1
70        },
71        "end": {
72          "line": 20,
73          "column": 68
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_dyn_decl",
197              "decorators": [],
198              "loc": {
199                "start": {
200                  "line": 22,
201                  "column": 10
202                },
203                "end": {
204                  "line": 22,
205                  "column": 21
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_dyn_decl",
221                  "decorators": [],
222                  "loc": {
223                    "start": {
224                      "line": 22,
225                      "column": 10
226                    },
227                    "end": {
228                      "line": 22,
229                      "column": 21
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": "ADeclared",
249                            "decorators": [],
250                            "loc": {
251                              "start": {
252                                "line": 22,
253                                "column": 25
254                              },
255                              "end": {
256                                "line": 22,
257                                "column": 34
258                              }
259                            }
260                          },
261                          "loc": {
262                            "start": {
263                              "line": 22,
264                              "column": 25
265                            },
266                            "end": {
267                              "line": 22,
268                              "column": 35
269                            }
270                          }
271                        },
272                        "loc": {
273                          "start": {
274                            "line": 22,
275                            "column": 25
276                          },
277                          "end": {
278                            "line": 22,
279                            "column": 35
280                          }
281                        }
282                      },
283                      "decorators": [],
284                      "loc": {
285                        "start": {
286                          "line": 22,
287                          "column": 22
288                        },
289                        "end": {
290                          "line": 22,
291                          "column": 35
292                        }
293                      }
294                    },
295                    "loc": {
296                      "start": {
297                        "line": 22,
298                        "column": 22
299                      },
300                      "end": {
301                        "line": 22,
302                        "column": 35
303                      }
304                    }
305                  }
306                ],
307                "returnType": {
308                  "type": "ETSPrimitiveType",
309                  "loc": {
310                    "start": {
311                      "line": 22,
312                      "column": 37
313                    },
314                    "end": {
315                      "line": 22,
316                      "column": 44
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": 23,
335                              "column": 12
336                            },
337                            "end": {
338                              "line": 23,
339                              "column": 13
340                            }
341                          }
342                        },
343                        "right": {
344                          "type": "ETSTypeReference",
345                          "part": {
346                            "type": "ETSTypeReferencePart",
347                            "name": {
348                              "type": "Identifier",
349                              "name": "JSValue",
350                              "decorators": [],
351                              "loc": {
352                                "start": {
353                                  "line": 23,
354                                  "column": 25
355                                },
356                                "end": {
357                                  "line": 23,
358                                  "column": 32
359                                }
360                              }
361                            },
362                            "loc": {
363                              "start": {
364                                "line": 23,
365                                "column": 25
366                              },
367                              "end": {
368                                "line": 23,
369                                "column": 33
370                              }
371                            }
372                          },
373                          "loc": {
374                            "start": {
375                              "line": 23,
376                              "column": 25
377                            },
378                            "end": {
379                              "line": 23,
380                              "column": 33
381                            }
382                          }
383                        },
384                        "loc": {
385                          "start": {
386                            "line": 23,
387                            "column": 12
388                          },
389                          "end": {
390                            "line": 23,
391                            "column": 33
392                          }
393                        }
394                      },
395                      "loc": {
396                        "start": {
397                          "line": 23,
398                          "column": 5
399                        },
400                        "end": {
401                          "line": 23,
402                          "column": 33
403                        }
404                      }
405                    }
406                  ],
407                  "loc": {
408                    "start": {
409                      "line": 22,
410                      "column": 45
411                    },
412                    "end": {
413                      "line": 24,
414                      "column": 2
415                    }
416                  }
417                },
418                "loc": {
419                  "start": {
420                    "line": 22,
421                    "column": 21
422                  },
423                  "end": {
424                    "line": 24,
425                    "column": 2
426                  }
427                }
428              },
429              "loc": {
430                "start": {
431                  "line": 22,
432                  "column": 21
433                },
434                "end": {
435                  "line": 24,
436                  "column": 2
437                }
438              }
439            },
440            "overloads": [],
441            "decorators": [],
442            "loc": {
443              "start": {
444                "line": 22,
445                "column": 1
446              },
447              "end": {
448                "line": 24,
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  "loc": {
478    "start": {
479      "line": 1,
480      "column": 1
481    },
482    "end": {
483      "line": 25,
484      "column": 1
485    }
486  }
487}
488