mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-10 00:47:45 +00:00

add suggestion on how to add a panic breakpoint Co-authored-by: Pat Pannuto <pat.pannuto@gmail.com> delete no_mangle from ui/panic-handler/panic-handler-wrong-location test issue an error for the usage of #[no_mangle] on internal language items delete the comments add newline rephrase note Co-authored-by: bjorn3 <17426603+bjorn3@users.noreply.github.com> update error not to leak implementation details delete no_mangle_span Co-authored-by: bjorn3 <17426603+bjorn3@users.noreply.github.com> delete commented code
17 lines
691 B
Plaintext
17 lines
691 B
Plaintext
error: `#[no_mangle]` cannot be used on internal language items
|
|
--> $DIR/no-mangle-on-panic-handler.rs:10:1
|
|
|
|
|
LL | #[unsafe(no_mangle)]
|
|
| ^^^^^^^^^^^^^^^^^^^^
|
|
LL | #[panic_handler]
|
|
LL | pub unsafe fn panic_fmt(pi: &PanicInfo) -> ! {
|
|
| -------------------------------------------- should be the internal language item
|
|
|
|
|
= note: Rustc requires this item to have a specific mangled name.
|
|
= note: If you are trying to prevent mangling to ease debugging, many
|
|
= note: debuggers support a command such as `rbreak rust_begin_unwind` to
|
|
= note: match `.*rust_begin_unwind.*` instead of `break rust_begin_unwind` on a specific name
|
|
|
|
error: aborting due to 1 previous error
|
|
|