rustc/tests/ui/rfcs/rfc-2091-track-caller/error-with-main.rs
2024-05-23 21:15:29 +02:00

5 lines
134 B
Rust

#[track_caller] //~ ERROR `main` function is not allowed to be
fn main() {
panic!("{}: oh no", std::panic::Location::caller());
}