mirror of
https://github.com/rust-lang/rust
synced 2024-10-02 23:04:50 +00:00
Updated docs on #[panic_handler]
in library/core/src/lib.rs
This commit is contained in:
parent
894f7a4ba6
commit
28ba5e4124
|
@ -34,12 +34,9 @@
|
||||||
//! Rust user code is to call the functions provided by this library instead (such as
|
//! Rust user code is to call the functions provided by this library instead (such as
|
||||||
//! `ptr::copy`).
|
//! `ptr::copy`).
|
||||||
//!
|
//!
|
||||||
//! * `rust_begin_panic` - This function takes four arguments, a
|
//! * Panic handler - This function takes one argument, a `&panic::PanicInfo`. It is up to consumers of this core
|
||||||
//! `fmt::Arguments`, a `&'static str`, and two `u32`'s. These four arguments
|
|
||||||
//! dictate the panic message, the file at which panic was invoked, and the
|
|
||||||
//! line and column inside the file. It is up to consumers of this core
|
|
||||||
//! library to define this panic function; it is only required to never
|
//! library to define this panic function; it is only required to never
|
||||||
//! return. This requires a `lang` attribute named `panic_impl`.
|
//! return. You should mark your implementation using `#[panic_handler]`.
|
||||||
//!
|
//!
|
||||||
//! * `rust_eh_personality` - is used by the failure mechanisms of the
|
//! * `rust_eh_personality` - is used by the failure mechanisms of the
|
||||||
//! compiler. This is often mapped to GCC's personality function, but crates
|
//! compiler. This is often mapped to GCC's personality function, but crates
|
||||||
|
|
Loading…
Reference in a new issue