mirror of
https://github.com/rustwasm/wasm-bindgen.git
synced 2024-12-16 05:59:21 +03:00
0e11e4a3bd
An extension trait for `Option<T>` and `Result<T, E>` for unwraping the `T` value, or throwing a JS error if it is not available. These methods should have a smaller code size footprint than the normal `Option::unwrap` and `Option::expect` methods, but they are specific to working with wasm and JS. On non-wasm32 targets, defaults to the normal unwrap/expect calls. |
||
---|---|---|
.. | ||
crates | ||
no-std | ||
wasm | ||
headless.rs | ||
non_wasm.rs | ||
std-crate-no-std-dep.rs | ||
unwrap_throw.rs |