Mark panic_fmt as no_mangle to work around rust-lang/rust#38281

(cherry picked from commit 081105bbb6)
(cherry picked from commit 1acc1ff5806f2fa101f726644d258eb4e4543540)
This commit is contained in:
Philipp Oppermann
2016-12-19 11:29:06 +01:00
parent 7c8f62d312
commit a46b3a13c4

View File

@@ -84,6 +84,7 @@ extern "C" fn eh_personality() {}
#[cfg(not(test))] #[cfg(not(test))]
#[lang = "panic_fmt"] #[lang = "panic_fmt"]
#[no_mangle]
extern "C" fn panic_fmt(fmt: core::fmt::Arguments, file: &'static str, line: u32) -> ! { extern "C" fn panic_fmt(fmt: core::fmt::Arguments, file: &'static str, line: u32) -> ! {
println!("\n\nPANIC in {} at line {}:", file, line); println!("\n\nPANIC in {} at line {}:", file, line);
println!(" {}", fmt); println!(" {}", fmt);