NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
crates.io · #1950 most downloaded on crates.io
const panic with formatting
Last release 1 months ago
17 Aug 2026
Release timing varies
gaps range from 3 weeks to 1.3 years
Most releases are documented
notes for 13 of 21 stable releases
Nothing withdrawn
no release was ever pulled
5 years old
21 releases · first in 2021
One column per quarter.
This release allows configuring the maximum length of formatted const panics with the CONST_PANIC_MAX_LENGTH environment variable.
This release allows configuring the maximum length of formatted const panics with the CONST_PANIC_MAX_LENGTH environment variable.
Changed maximum length of formatted panicking to be configurable using CONST_PANIC_MAX_LENGTH environment variable
Added ArrayString::is_empty method
Removed #[automatically_derived] on generated inherent impls, which triggers a rustc future compatibility warning.
Shrunk the maximum length of panics on 16-bit platforms to 512 bytes to support them.
Fixed triggering òf missing_docs lint in downstream crates by adding docs to items generated by impl_panicfmt macro and PanicFmt derive
Added const_panic::fmt::CoerceReturn trait
Added const_panic::fmt::CoerceReturnOutput type alias
Changed IsPanicFmt::coerce from two inherent methods to one generic inherent method. This improves compile-time error messages when the argument doesn't impl PanicFmt.
Shrunk the maximum length of panics on 16-bit platforms to 512 bytes to support them.
Shrunk the maximum length of panics on 16-bit platforms to 512 bytes to support them.
Fixed triggering òf missing_docs lint in downstream crates by adding docs to items generated by impl_panicfmt macro and PanicFmt derive
Fixed triggering òf missing_docs lint in downstream crates by adding docs to items generated by impl_panicfmt macro and PanicFmt derive
Added const_panic::CoerceReturn trait
Added const_panic::fmt::CoerceReturn trait
Added const_panic::fmt::CoerceReturnOutput type alias
Changed IsPanicFmt::coerce from two inherent methods to one generic inherent method. This improves compile-time error messages when the argument doesn't impl PanicFmt.
This release adds a few more PanicFmt impls
This release adds a few more PanicFmt impls
Added rust_1_88 feature.
Added PanicFmt impls for:
core::ffi::c_str::FromBytesWithNulError (requires rust_1_88 feature)core::ffi::c_str::FromBytesUntilNulError (requires rust_1_88 feature)core::convert::InfallibleThis release makes it possible to override Display formatting when the PanicFmt trait is derived.
This release makes it possible to override Display formatting when the PanicFmt trait is derived.
Added these helper attributes to PanicFmt derive and impl_panicfmt macro:
#[pfmt(display_fmt = ...)]#[pfmt(panicvals_lower_bound = ...)]Added const_panic::utils::{min_usize, max_usize}
Added formatting for core::num::{IntErrorKind, ParseIntError}
Added "rust_1_82" and "rust_latest_stable" features
Added formatting for core::{IntErrorKind, ParseIntError}
Added formatting for core::num::{IntErrorKind, ParseIntError}
Added "rust_1_82" and "rust_latest_stable" features
This release fixes how panicking is implemented to not add nul bytes after what the user prints in a panic.
This release fixes how panicking is implemented to not add nul bytes after what the user prints in a panic.
Fixed internal use of the panic macro to not append nul bytes to the output.
Added const_panic::utils::bytes_up_to function.
Nothing published for this version
Nothing published for this version
This release adds a concat_ macro, for concatenating PanicFmt values into a &'static str .
This release adds a concat_ macro, for concatenating PanicFmt values into a &'static str.
Added concat_ macro, which requires "non_basic" feature.
Added TypeDelim::{close, open} methods.
Made ArrayString::as_bytes take constant time when the "rust_1_64" feature is enabled.
Made "derive" feature enable "non_basic" feature.
Added konst_kernel = 0.3 dependency, enabled by "non_basic" feature.
Nothing published for this version
Adds char , slice-of- char , and core::Utf8Error formatting support.
Adds char, slice-of-char, and core::str::Utf8Error formatting support.
Added "rust_1_64" feature, which enables formatting impls which require newer versions.
Added core::str::Utf8Error formatting (requires "rust_1_64" feature)
Added formatting support for char and slices of char.
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Made breaking changes to impl_panicfmt to allow generic implementations with type and const parameters.
This release adds a PanicFmt derive, generic type support to impl_panicfmt macro, hexadecimal/binary formatting, and a concat_assert assertion macro.
Added concat_assert macro.
Added PanicFmt derive macro.
Added "derive" crate feature, to enable the PanicFmt derive.
Made breaking changes to impl_panicfmt to allow generic implementations with type and const parameters.
Added NumberFmt enum, for choosing how numbers are formatted.
Added FmtArg::{BIN, ALT_BIN, HEX. ALT_HEX} associated constants.
Added FmtArg::{set_hex, set_bin} methods.
Added PanicVal::from_short_str constructor.
Added support for binary and hexadecimal formatting in macros.
Added PackedFmtArg type (which requires the non_basic feature).
Added const_panic::fmt::SHORT_STRING_CAP constant with the capacity of a ShortString.
Changed PanicVal such that only strings can be left or right padded.
Removed the PanicVal::{set_leftpad, set_rightpad} methods.
Declared const_panic_proc_macros crate, depended by const_panic when the "derive" feature is enabled.
Added PanicFmt-based formatting for these types(all of which require the "non_basic" feature):
Options of integer, bool, and &strOptions of arrays and slices (of integer, bool, and &str)NonZero* integers, and Options of themNonNull, and Options of them*const T and *mut Tstd::cmp::Ordering, and Options of themstd::sync::atomic::Orderingstd::ops::Range* types, parameterized with usize.()std::marker::PhantomDatastd::marker::PhantomPinnedStdWrapperAdded these macros:
unwrap_okunwrap_errunwrap_someFixed signature of to_panicvals for arrays and slices of PanicVals, by adding a FmtArg parameter.
Added PanicFmt-based formatting for these types(all of which require the "non_basic" feature):
Added PanicFmt-based formatting for these types(all of which require the "non_basic" feature):
Options of integer, bool, and &strOptions of arrays and slices (of integer, bool, and &str)NonZero* integers, and Options of themNonNull, and Options of them*const T and *mut Tstd::cmp::Ordering, and Options of themstd::sync::atomic::Orderingstd::ops::Range* types, parameterized with usize.()std::marker::PhantomDatastd::marker::PhantomPinnedStdWrapperAdded these macros:
unwrap_okunwrap_errunwrap_someFixed signature of to_panicvals for arrays and slices of PanicVals, by adding a FmtArg parameter.
This initial release comes with the ability to do const panics with formatting. The types that can be formatted are all the primitive types, and user-
This initial release comes with the ability to do const panics with formatting.
The types that can be formatted are all the primitive types, and user-defined types that implement formatting by using the macros from this crate.
Defined the fmt::PanicFmt trait.
Defined these types in the fmt module:
ComputePvCountFmtArgIsCustomTypeIsStdTypeIsPanicFMtSeparatorDelimiterFmtKindIsLastTypeDelimShortString (type alias for ArrayString<16>)Defined these constants in the fmt module:
COMMA_SEPCOMMA_TERMINDENTATION_STEPRe-exported these variants from fmt::Delimiter in fmt:
CloseBraceCloseBracketCloseParenEmpty renamed to EmptyDelimiterOpenBraceOpenBracketOpenParenReexported these items from fmt in the root module:
FmtArgIsCustomTypePanicFmtComputePvCountTypeDelimDefined these macros:
coerce_fmtconcat_panic: for panicking with formatted arguments.flatten_panicvals: for flattening the argument slices of PanicVals into an array.impl_panicfmt: for user-defined structs and enums to implement PanicFmtinline_macroImplemented PanicFmt-based formatting for:
strboolPanicVal integers, bool, and &str.Defined the ArrayString stack allocated string type.
Defined the PanicVal opaque enum used for formatting.
Defined the StdWrapper wrapper type for defining methods on std types
Defined the concat_panic function, for panicking with formatted arguments.
Defined the "non_basic" crate feature,
which enables all items for doing more than panicking with primitive types.
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →