[−][src]Struct panic_write::PanicHandler
Implementations
impl<W: Write> PanicHandler<W>
[src]
#[must_use = "the panic handler must be kept in scope"]pub fn new(writer: W) -> Pin<Self>
[src]
Create a panic handler from a core::fmt::Write
Note that the returned handler is detached when it goes out of scope so in most cases it's desired to keep the handler in scope for the full duration of the program.
Additionally, the panic handler implements Deref
for the provided Write
and can be used
in place of the original Write
throughout the app.
pub fn detach(handler: Pin<Self>) -> W
[src]
Detach this panic handler and return the underlying writer
Trait Implementations
impl<W: Write> Deref for PanicHandler<W>
[src]
impl<W: Write> DerefMut for PanicHandler<W>
[src]
impl<W: Write> Drop for PanicHandler<W>
[src]
Auto Trait Implementations
impl<W> Send for PanicHandler<W> where
W: Send,
W: Send,
impl<W> Sync for PanicHandler<W> where
W: Sync,
W: Sync,
impl<W> !Unpin for PanicHandler<W>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,