rust/src/test/ui/rfc-2091-track-caller/error-with-naked.rs
2020-04-08 03:49:53 +02:00

22 lines
392 B
Rust

#![feature(naked_functions, track_caller)]
#[track_caller] //~ ERROR cannot use `#[track_caller]` with `#[naked]`
#[naked]
fn f() {}
struct S;
impl S {
#[track_caller] //~ ERROR cannot use `#[track_caller]` with `#[naked]`
#[naked]
fn g() {}
}
extern "Rust" {
#[track_caller] //~ ERROR cannot use `#[track_caller]` with `#[naked]`
#[naked]
fn h();
}
fn main() {}