Sha256: f3ab249b3741b38c6213651a5cd36f8b9873bad34bd49d13b780d21bed47272b

Contents?: true

Size: 1.05 KB

Versions: 30

Compression:

Stored size: 1.05 KB

Contents

#![allow(unreachable_code)]
use wasm_bindgen::prelude::*;

#[wasm_bindgen]
pub struct MyType;

#[wasm_bindgen]
pub async fn good1() { loop {} }
#[wasm_bindgen]
pub async fn good2() -> JsValue { loop {} }
#[wasm_bindgen]
pub async fn good3() -> u32 { loop {} }
#[wasm_bindgen]
pub async fn good4() -> MyType { loop {} }
#[wasm_bindgen]
pub async fn good5() -> Result<(), JsValue> { loop {} }
#[wasm_bindgen]
pub async fn good6() -> Result<JsValue, JsValue> { loop {} }
#[wasm_bindgen]
pub async fn good7() -> Result<u32, JsValue> { loop {} }
#[wasm_bindgen]
pub async fn good8() -> Result<MyType, JsValue> { loop {} }
#[wasm_bindgen]
pub async fn good9() -> Result<MyType, u32> { loop {} }
#[wasm_bindgen]
pub async fn good10() -> Result<MyType, MyType> { loop {} }

pub struct BadType;

#[wasm_bindgen]
pub async fn bad1() -> Result<(), ()> { loop {} }
#[wasm_bindgen]
pub async fn bad2() -> Result<(), BadType> { loop {} }
#[wasm_bindgen]
pub async fn bad3() -> BadType { loop {} }
#[wasm_bindgen]
pub async fn bad4() -> Result<BadType, JsValue> { loop {} }


fn main() {}

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
wasmtime-23.0.2 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-22.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-21.0.1 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-20.0.2 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-20.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-18.0.3 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-17.0.1 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-17.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-16.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-15.0.1 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-15.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.89/ui-tests/async-errors.rs
wasmtime-14.0.4 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-14.0.3 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-14.0.1 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-14.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-13.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-12.0.1 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-12.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-11.0.0 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs
wasmtime-10.0.1 ./ext/cargo-vendor/wasm-bindgen-macro-0.2.87/ui-tests/async-errors.rs