diff --git a/core/src/fmt/rt.rs b/core/src/fmt/rt.rs index 65a4d537cc74d..f29ac99b29255 100644 --- a/core/src/fmt/rt.rs +++ b/core/src/fmt/rt.rs @@ -118,6 +118,10 @@ impl<'a> Argument<'a> { Self::new(x, Debug::fmt) } #[inline(always)] + pub fn new_debug_noop<'b, T: Debug>(x: &'b T) -> Argument<'_> { + Self::new(x, |_, _| Ok(())) + } + #[inline(always)] pub fn new_octal<'b, T: Octal>(x: &'b T) -> Argument<'_> { Self::new(x, Octal::fmt) }