mirror of
https://github.com/embassy-rs/embassy.git
synced 2025-09-30 22:01:07 +00:00
17 lines
335 B
Rust
17 lines
335 B
Rust
#![cfg_attr(feature = "nightly", feature(impl_trait_in_assoc_type))]
|
|
|
|
use core::future::Future;
|
|
|
|
use embassy_executor::SendSpawner;
|
|
|
|
#[embassy_executor::task]
|
|
async fn task(non_send: *mut ()) {
|
|
println!("{}", non_send as usize);
|
|
}
|
|
|
|
fn send_spawn(s: SendSpawner) {
|
|
s.spawn(task(core::ptr::null_mut())).unwrap();
|
|
}
|
|
|
|
fn main() {}
|