]> git.lizzy.rs Git - rust.git/blob - tests/ui/async-await/unreachable-lint-1.rs
Rollup merge of #107027 - GuillaumeGomez:rm-extra-removal, r=tmiasko
[rust.git] / tests / ui / async-await / unreachable-lint-1.rs
1 // edition:2018
2 #![deny(unreachable_code)]
3
4 async fn foo() {
5     return; bar().await;
6     //~^ ERROR unreachable statement
7 }
8
9 async fn bar() {
10 }
11
12 fn main() { }