Debian Codegraph @

crates/wit-parser/tests/ui/async.wit.json

raw
1 {
2 "worlds": [
3 {
4 "name": "y",
5 "imports": {
6 "[async]x": {
7 "function": {
8 "name": "[async]x",
9 "kind": "async-freestanding",
10 "params": []
11 }
12 },
13 "y": {
14 "function": {
15 "name": "y",
16 "kind": "freestanding",
17 "params": []
18 }
19 }
20 },
21 "exports": {
22 "[async]x": {
23 "function": {
24 "name": "[async]x",
25 "kind": "async-freestanding",
26 "params": []
27 }
28 },
29 "y": {
30 "function": {
31 "name": "y",
32 "kind": "freestanding",
33 "params": []
34 }
35 }
36 },
37 "package": 0
38 }
39 ],
40 "interfaces": [
41 {
42 "name": "x",
43 "types": {
44 "z": 0
45 },
46 "functions": {
47 "[async]x": {
48 "name": "[async]x",
49 "kind": "async-freestanding",
50 "params": [
51 {
52 "name": "x",
53 "type": "u32"
54 }
55 ],
56 "result": "u64"
57 },
58 "y": {
59 "name": "y",
60 "kind": "freestanding",
61 "params": []
62 },
63 "[constructor]z": {
64 "name": "[constructor]z",
65 "kind": {
66 "constructor": 0
67 },
68 "params": [],
69 "result": 2
70 },
71 "[async method]z.x": {
72 "name": "[async method]z.x",
73 "kind": {
74 "async-method": 0
75 },
76 "params": [
77 {
78 "name": "self",
79 "type": 1
80 }
81 ]
82 },
83 "[method]z.y": {
84 "name": "[method]z.y",
85 "kind": {
86 "method": 0
87 },
88 "params": [
89 {
90 "name": "self",
91 "type": 1
92 }
93 ]
94 },
95 "[async static]z.static-x": {
96 "name": "[async static]z.static-x",
97 "kind": {
98 "async-static": 0
99 },
100 "params": []
101 },
102 "[static]z.static-y": {
103 "name": "[static]z.static-y",
104 "kind": {
105 "static": 0
106 },
107 "params": []
108 }
109 },
110 "package": 0
111 }
112 ],
113 "types": [
114 {
115 "name": "z",
116 "kind": "resource",
117 "owner": {
118 "interface": 0
119 }
120 },
121 {
122 "name": null,
123 "kind": {
124 "handle": {
125 "borrow": 0
126 }
127 },
128 "owner": null
129 },
130 {
131 "name": null,
132 "kind": {
133 "handle": {
134 "own": 0
135 }
136 },
137 "owner": null
138 }
139 ],
140 "packages": [
141 {
142 "name": "test:async",
143 "interfaces": {
144 "x": 0
145 },
146 "worlds": {
147 "y": 0
148 }
149 }
150 ]
151 }