Debian Codegraph @

crates/wit-component/tests/components/resource-using-export/component.wat

raw
1 (component
2 (core module (;0;)
3 (type (;0;) (func (param i32) (result i32)))
4 (type (;1;) (func (result i32)))
5 (import "[export]foo:bar/foo" "[resource-new]r" (func $new (;0;) (type 0)))
6 (export "anon#f" (func 1))
7 (func (;1;) (type 1) (result i32)
8 i32.const 100
9 call $new
10 )
11 (@producers
12 (processed-by "wit-component" "$CARGO_PKG_VERSION")
13 (processed-by "my-fake-bindgen" "123.45")
14 )
15 )
16 (type (;0;) (resource (rep i32)))
17 (type (;1;) (own 0))
18 (core func (;0;) (canon resource.new 0))
19 (core instance (;0;)
20 (export "[resource-new]r" (func 0))
21 )
22 (core instance (;1;) (instantiate 0
23 (with "[export]foo:bar/foo" (instance 0))
24 )
25 )
26 (component (;0;)
27 (import "import-type-r" (type (;0;) (sub resource)))
28 (export (;1;) "r" (type 0))
29 (type (;2;) (own 1))
30 (export (;3;) "handle" (type 2))
31 )
32 (instance (;0;) (instantiate 0
33 (with "import-type-r" (type 0))
34 )
35 )
36 (export (;1;) "foo:bar/foo" (instance 0))
37 (type (;2;) (func (result 1)))
38 (alias core export 1 "anon#f" (core func (;1;)))
39 (func (;0;) (type 2) (canon lift (core func 1)))
40 (alias export 1 "r" (type (;3;)))
41 (alias export 1 "handle" (type (;4;)))
42 (component (;1;)
43 (import "import-type-r" (type (;0;) (sub resource)))
44 (type (;1;) (own 0))
45 (import "import-type-handle" (type (;2;) (eq 1)))
46 (import "import-type-handle0" (type (;3;) (eq 2)))
47 (type (;4;) (func (result 3)))
48 (import "import-func-f" (func (;0;) (type 4)))
49 (export (;5;) "handle" (type 2))
50 (type (;6;) (func (result 5)))
51 (export (;1;) "f" (func 0) (func (type 6)))
52 )
53 (instance (;2;) (instantiate 1
54 (with "import-func-f" (func 0))
55 (with "import-type-r" (type 3))
56 (with "import-type-handle" (type 4))
57 (with "import-type-handle0" (type 1))
58 )
59 )
60 (export (;3;) "anon" (instance 2))
61 (@producers
62 (processed-by "wit-component" "$CARGO_PKG_VERSION")
63 )
64 )