forked from mirrors/gecko-dev
Updated uniffi-bindgen-gecko-js to work with UniFFI 0.25.2: - Use `config.toml` to list UniFFI sources. This makes it easier to associate data with them, for example the `crate_name` field that's now required to generate the sources. - Enable the `extern-rustbuffer` feature on `uniffi_core` - Updated the external types fixture to work around https://github.com/mozilla/uniffi-rs/issues/1872 Ran mach vendor and mach cargo vet to update the Rust crates. Differential Revision: https://phabricator.services.mozilla.com/D195163
11 lines
275 B
Rust
11 lines
275 B
Rust
#[cfg(feature = "std")]
|
|
fn main() {
|
|
let (sender, receiver) = oneshot::channel::<u128>();
|
|
std::mem::drop(sender);
|
|
receiver.recv().unwrap_err();
|
|
}
|
|
|
|
#[cfg(not(feature = "std"))]
|
|
fn main() {
|
|
panic!("This example is only for when the \"sync\" feature is used");
|
|
}
|