rust/src/test/compile-fail/panic-handler-twice.rs

19 lines
300 B
Rust
Raw Normal View History

2018-05-29 10:33:11 +00:00
// aux-build:some-panic-impl.rs
#![feature(lang_items)]
#![no_std]
#![no_main]
extern crate some_panic_impl;
use core::panic::PanicInfo;
#[panic_handler]
2018-05-29 10:33:11 +00:00
fn panic(info: &PanicInfo) -> ! {
//~^ error duplicate lang item found: `panic_impl`
loop {}
}
#[lang = "eh_personality"]
fn eh() {}