rust/tests/ui/async-await/no-unsafe-async.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
269 B
Rust
Raw Normal View History

//@ edition:2018
struct S;
impl S {
2025-03-29 17:24:03 +00:00
#[cfg(false)]
2019-10-22 11:46:19 -07:00
unsafe async fn g() {} //~ ERROR expected one of `extern` or `fn`, found keyword `async`
}
2025-03-29 17:24:03 +00:00
#[cfg(false)]
unsafe async fn f() {} //~ ERROR expected one of `extern` or `fn`, found keyword `async`
fn main() {}