]> git.lizzy.rs Git - rust.git/blob - tests/ui/async-await/no-move-across-await-tuple.rs
Rollup merge of #106836 - ibraheemdev:sync-sender-spin, r=Amanieu
[rust.git] / tests / ui / async-await / no-move-across-await-tuple.rs
1 // edition:2018
2 // compile-flags: --crate-type lib
3
4 async fn no_move_across_await_tuple() -> Vec<usize> {
5     let x = (vec![3], vec![4, 4]);
6     drop(x.1);
7     nothing().await;
8     x.1
9     //~^ ERROR use of moved value: `x.1`
10 }
11
12 async fn nothing() {}