summaryrefslogtreecommitdiffstats
path: root/tests/ui/async-await/unreachable-lint-1.rs
blob: d63d643c4e70b05dc84b03670efceabb59f1d468 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// edition:2018
#![deny(unreachable_code)]

async fn foo() {
    return; bar().await;
    //~^ ERROR unreachable statement
}

async fn bar() {
}

fn main() { }