Module const_panic::fmt

source ·
Expand description

Formatting-related items

Panic formatting for custom types can be done in these ways (in increasing order of verbosity):

  • Using the PanicFmt derive macro (requires the opt-in "derive" feature)
  • Using the impl_panicfmt macro (requires the default-enabled "non_basic" feature)
  • Using the flatten_panicvals macro (requires the default-enabled "non_basic" feature)
  • Manually implementing the PanicFmt trait as described in its docs.

Re-exports

Modules

Structs

Enums

  • Delimiternon_basic
    For outputting an alternate flag-aware delimiter.
  • What kind of formatting to do, either Display or Debug.
  • IsLastnon_basic
    For telling Separator whether it comes after the last field or not.
  • What integers are formatted as.
  • TypeDelimnon_basic
    Whether a struct or variant is Tupled or Braced.

Constants

Traits

  • Trait for types that can be formatted by const panics.

Type Definitions