wit-component 0.246.2

Tooling for working with `*.wit` and component files together.
Documentation
(component
  (core module $main (;0;)
    (type (;0;) (func (result i64)))
    (type (;1;) (func (param i32 i32) (result i32)))
    (type (;2;) (func (param i32) (result i32)))
    (type (;3;) (func (param i32)))
    (type (;4;) (func (param i32 i32 i32) (result i32)))
    (import "$root" "[future-new-unit]foo" (func (;0;) (type 0)))
    (import "$root" "[future-read-unit]foo" (func (;1;) (type 1)))
    (import "$root" "[future-write-unit]foo" (func (;2;) (type 1)))
    (import "$root" "[future-cancel-read-unit]foo" (func (;3;) (type 2)))
    (import "$root" "[future-cancel-write-unit]foo" (func (;4;) (type 2)))
    (import "$root" "[future-drop-readable-unit]foo" (func (;5;) (type 3)))
    (import "$root" "[future-drop-writable-unit]foo" (func (;6;) (type 3)))
    (import "$root" "[stream-new-unit]foo" (func (;7;) (type 0)))
    (import "$root" "[stream-read-unit]foo" (func (;8;) (type 4)))
    (import "$root" "[stream-write-unit]foo" (func (;9;) (type 4)))
    (import "$root" "[stream-cancel-read-unit]foo" (func (;10;) (type 2)))
    (import "$root" "[stream-cancel-write-unit]foo" (func (;11;) (type 2)))
    (import "$root" "[stream-drop-readable-unit]foo" (func (;12;) (type 3)))
    (import "$root" "[stream-drop-writable-unit]foo" (func (;13;) (type 3)))
    (memory (;0;) 1)
    (export "memory" (memory 0))
    (@producers
      (processed-by "wit-component" "$CARGO_PKG_VERSION")
      (processed-by "my-fake-bindgen" "123.45")
    )
  )
  (core module $wit-component-shim-module (;1;)
    (type (;0;) (func (param i32 i32) (result i32)))
    (type (;1;) (func (param i32 i32 i32) (result i32)))
    (table (;0;) 4 4 funcref)
    (export "0" (func $"$root-[future-read-unit]foo"))
    (export "1" (func $"$root-[future-write-unit]foo"))
    (export "2" (func $"$root-[stream-read-unit]foo"))
    (export "3" (func $"$root-[stream-write-unit]foo"))
    (export "$imports" (table 0))
    (func $"$root-[future-read-unit]foo" (;0;) (type 0) (param i32 i32) (result i32)
      local.get 0
      local.get 1
      i32.const 0
      call_indirect (type 0)
    )
    (func $"$root-[future-write-unit]foo" (;1;) (type 0) (param i32 i32) (result i32)
      local.get 0
      local.get 1
      i32.const 1
      call_indirect (type 0)
    )
    (func $"$root-[stream-read-unit]foo" (;2;) (type 1) (param i32 i32 i32) (result i32)
      local.get 0
      local.get 1
      local.get 2
      i32.const 2
      call_indirect (type 1)
    )
    (func $"$root-[stream-write-unit]foo" (;3;) (type 1) (param i32 i32 i32) (result i32)
      local.get 0
      local.get 1
      local.get 2
      i32.const 3
      call_indirect (type 1)
    )
    (@producers
      (processed-by "wit-component" "$CARGO_PKG_VERSION")
    )
  )
  (core module $wit-component-fixup (;2;)
    (type (;0;) (func (param i32 i32) (result i32)))
    (type (;1;) (func (param i32 i32 i32) (result i32)))
    (import "" "0" (func (;0;) (type 0)))
    (import "" "1" (func (;1;) (type 0)))
    (import "" "2" (func (;2;) (type 1)))
    (import "" "3" (func (;3;) (type 1)))
    (import "" "$imports" (table (;0;) 4 4 funcref))
    (elem (;0;) (i32.const 0) func 0 1 2 3)
    (@producers
      (processed-by "wit-component" "$CARGO_PKG_VERSION")
    )
  )
  (core instance $wit-component-shim-instance (;0;) (instantiate $wit-component-shim-module))
  (type (;0;) (future))
  (core func $future.new (;0;) (canon future.new 0))
  (alias core export $wit-component-shim-instance "0" (core func $"$root-[future-read-unit]foo" (;1;)))
  (alias core export $wit-component-shim-instance "1" (core func $"$root-[future-write-unit]foo" (;2;)))
  (core func $future.cancel-read (;3;) (canon future.cancel-read 0))
  (core func $future.cancel-write (;4;) (canon future.cancel-write 0))
  (core func $future.drop-readable (;5;) (canon future.drop-readable 0))
  (core func $future.drop-writable (;6;) (canon future.drop-writable 0))
  (type (;1;) (stream))
  (core func $stream.new (;7;) (canon stream.new 1))
  (alias core export $wit-component-shim-instance "2" (core func $"$root-[stream-read-unit]foo" (;8;)))
  (alias core export $wit-component-shim-instance "3" (core func $"$root-[stream-write-unit]foo" (;9;)))
  (core func $stream.cancel-read (;10;) (canon stream.cancel-read 1))
  (core func $stream.cancel-write (;11;) (canon stream.cancel-write 1))
  (core func $stream.drop-readable (;12;) (canon stream.drop-readable 1))
  (core func $stream.drop-writable (;13;) (canon stream.drop-writable 1))
  (core instance $$root (;1;)
    (export "[future-new-unit]foo" (func $future.new))
    (export "[future-read-unit]foo" (func $"$root-[future-read-unit]foo"))
    (export "[future-write-unit]foo" (func $"$root-[future-write-unit]foo"))
    (export "[future-cancel-read-unit]foo" (func $future.cancel-read))
    (export "[future-cancel-write-unit]foo" (func $future.cancel-write))
    (export "[future-drop-readable-unit]foo" (func $future.drop-readable))
    (export "[future-drop-writable-unit]foo" (func $future.drop-writable))
    (export "[stream-new-unit]foo" (func $stream.new))
    (export "[stream-read-unit]foo" (func $"$root-[stream-read-unit]foo"))
    (export "[stream-write-unit]foo" (func $"$root-[stream-write-unit]foo"))
    (export "[stream-cancel-read-unit]foo" (func $stream.cancel-read))
    (export "[stream-cancel-write-unit]foo" (func $stream.cancel-write))
    (export "[stream-drop-readable-unit]foo" (func $stream.drop-readable))
    (export "[stream-drop-writable-unit]foo" (func $stream.drop-writable))
  )
  (core instance $main (;2;) (instantiate $main
      (with "$root" (instance $$root))
    )
  )
  (alias core export $main "memory" (core memory $memory (;0;)))
  (alias core export $wit-component-shim-instance "$imports" (core table $"shim table" (;0;)))
  (core func $future.read (;14;) (canon future.read 0 (memory $memory)))
  (core func $future.write (;15;) (canon future.write 0 (memory $memory)))
  (core func $stream.read (;16;) (canon stream.read 1 (memory $memory)))
  (core func $stream.write (;17;) (canon stream.write 1 (memory $memory)))
  (core instance $fixup-args (;3;)
    (export "$imports" (table $"shim table"))
    (export "0" (func $future.read))
    (export "1" (func $future.write))
    (export "2" (func $stream.read))
    (export "3" (func $stream.write))
  )
  (core instance $fixup (;4;) (instantiate $wit-component-fixup
      (with "" (instance $fixup-args))
    )
  )
  (@producers
    (processed-by "wit-component" "$CARGO_PKG_VERSION")
  )
)