Sha256: 314b291d6284328fdf385c5680ffb5c7f56e8843de18a04c596b9de2a62a492f

Contents?: true

Size: 849 Bytes

Versions: 11

Compression:

Stored size: 849 Bytes

Contents

bindgen!({
    inline: r#"
        package example:world-exports;

        world with-exports {
            import log: func(msg: string);

            export run: func();

            /// An example of exporting an interface inline and naming it
            /// directly.
            export environment: interface {
                get: func(var: string) -> string;
                set: func(var: string, val: string);
            }

            /// An example of exporting an interface.
            export units;
        }

        interface units {
            /// Renders the number of bytes as a human readable string.
            bytes-to-string: func(bytes: u64) -> string;

            /// Renders the provided duration as a human readable string.
            duration-to-string: func(seconds: u64, ns: u32) -> string;
        }
    "#,
});

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
wasmtime-30.0.2 ./ext/cargo-vendor/wasmtime-30.0.2/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-29.0.0 ./ext/cargo-vendor/wasmtime-29.0.0/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-28.0.0 ./ext/cargo-vendor/wasmtime-28.0.0/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-27.0.0 ./ext/cargo-vendor/wasmtime-27.0.0/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-26.0.0 ./ext/cargo-vendor/wasmtime-26.0.0/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-25.0.2 ./ext/cargo-vendor/wasmtime-25.0.2/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-25.0.1 ./ext/cargo-vendor/wasmtime-25.0.1/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-25.0.0 ./ext/cargo-vendor/wasmtime-25.0.0/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-24.0.0 ./ext/cargo-vendor/wasmtime-24.0.0/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-23.0.2 ./ext/cargo-vendor/wasmtime-23.0.2/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs
wasmtime-22.0.0 ./ext/cargo-vendor/wasmtime-22.0.0/src/runtime/component/bindgen_examples/_5_all_world_export_kinds.rs