Files
tokio/tests-integration/tests/macros_pin.rs
T

13 lines
204 B
Rust
Raw Normal View History

2020-01-23 14:40:43 -08:00
use futures::executor::block_on;
async fn my_async_fn() {}
#[test]
fn pin() {
block_on(async {
let future = my_async_fn();
tokio::pin!(future);
(&mut future).await
});
}