Skip to main content Skip to main content
Pigweed's logo Pigweed
  1. Home
  2. Reference
  3. Rust
  4. pw_assert
  5. panic

panic

Macro panic 

Source
macro_rules! panic {
    ($($arg:tt)*) => { ... };
}
Expand description

Panics unconditionally.

This macro delegates to the backend macro panic_backend!.

§Examples

pw_assert::panic!("Something went terribly wrong!");

pw_assert::panic!("Error code: {}", 42 as i32);