Debian Codegraph @

packages/babel-parser/test/fixtures/flow/pragma/5/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":74,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":5,"column":10,"index":74}},
4 "program": {
5 "type": "Program",
6 "start":0,"end":74,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":5,"column":10,"index":74}},
7 "sourceType": "module",
8 "interpreter": {
9 "type": "InterpreterDirective",
10 "start":0,"end":19,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":19,"index":19}},
11 "value": "/usr/bin/env node"
12 },
13 "body": [
14 {
15 "type": "ExpressionStatement",
16 "start":64,"end":74,"loc":{"start":{"line":5,"column":0,"index":64},"end":{"line":5,"column":10,"index":74}},
17 "expression": {
18 "type": "CallExpression",
19 "start":64,"end":73,"loc":{"start":{"line":5,"column":0,"index":64},"end":{"line":5,"column":9,"index":73}},
20 "callee": {
21 "type": "Identifier",
22 "start":64,"end":67,"loc":{"start":{"line":5,"column":0,"index":64},"end":{"line":5,"column":3,"index":67},"identifierName":"foo"},
23 "name": "foo"
24 },
25 "typeArguments": {
26 "type": "TypeParameterInstantiation",
27 "start":67,"end":70,"loc":{"start":{"line":5,"column":3,"index":67},"end":{"line":5,"column":6,"index":70}},
28 "params": [
29 {
30 "type": "GenericTypeAnnotation",
31 "start":68,"end":69,"loc":{"start":{"line":5,"column":4,"index":68},"end":{"line":5,"column":5,"index":69}},
32 "typeParameters": null,
33 "id": {
34 "type": "Identifier",
35 "start":68,"end":69,"loc":{"start":{"line":5,"column":4,"index":68},"end":{"line":5,"column":5,"index":69},"identifierName":"x"},
36 "name": "x"
37 }
38 }
39 ]
40 },
41 "arguments": [
42 {
43 "type": "Identifier",
44 "start":71,"end":72,"loc":{"start":{"line":5,"column":7,"index":71},"end":{"line":5,"column":8,"index":72},"identifierName":"y"},
45 "name": "y"
46 }
47 ]
48 },
49 "leadingComments": [
50 {
51 "type": "CommentLine",
52 "value": " arbitrary comment",
53 "start":34,"end":54,"loc":{"start":{"line":3,"column":0,"index":34},"end":{"line":3,"column":20,"index":54}}
54 },
55 {
56 "type": "CommentLine",
57 "value": " @flow",
58 "start":55,"end":63,"loc":{"start":{"line":4,"column":0,"index":55},"end":{"line":4,"column":8,"index":63}}
59 }
60 ]
61 }
62 ],
63 "directives": [
64 {
65 "type": "Directive",
66 "start":20,"end":33,"loc":{"start":{"line":2,"column":0,"index":20},"end":{"line":2,"column":13,"index":33}},
67 "value": {
68 "type": "DirectiveLiteral",
69 "start":20,"end":32,"loc":{"start":{"line":2,"column":0,"index":20},"end":{"line":2,"column":12,"index":32}},
70 "extra": {
71 "rawValue": "use strict",
72 "raw": "'use strict'",
73 "expressionValue": "use strict"
74 },
75 "value": "use strict"
76 },
77 "trailingComments": [
78 {
79 "type": "CommentLine",
80 "value": " arbitrary comment",
81 "start":34,"end":54,"loc":{"start":{"line":3,"column":0,"index":34},"end":{"line":3,"column":20,"index":54}}
82 },
83 {
84 "type": "CommentLine",
85 "value": " @flow",
86 "start":55,"end":63,"loc":{"start":{"line":4,"column":0,"index":55},"end":{"line":4,"column":8,"index":63}}
87 }
88 ]
89 }
90 ]
91 },
92 "comments": [
93 {
94 "type": "CommentLine",
95 "value": " arbitrary comment",
96 "start":34,"end":54,"loc":{"start":{"line":3,"column":0,"index":34},"end":{"line":3,"column":20,"index":54}}
97 },
98 {
99 "type": "CommentLine",
100 "value": " @flow",
101 "start":55,"end":63,"loc":{"start":{"line":4,"column":0,"index":55},"end":{"line":4,"column":8,"index":63}}
102 }
103 ]
104 }