]> git.lizzy.rs Git - rust.git/blob - tests/ui/lint/must_not_suspend/gated.rs
Rollup merge of #106638 - RalfJung:realstd, r=thomcc
[rust.git] / tests / ui / lint / must_not_suspend / gated.rs
1 // check-pass
2
3 // edition:2018
4 #![deny(must_not_suspend)]
5 //~^ WARNING unknown lint: `must_not_suspend`
6 //~| WARNING unknown lint: `must_not_suspend`
7 //~| WARNING unknown lint: `must_not_suspend`
8
9 async fn other() {}
10
11 pub async fn uhoh(m: std::sync::Mutex<()>) {
12     let _guard = m.lock().unwrap();
13     other().await;
14 }
15
16 fn main() {
17 }