From 9e6785430b2253315a4ce31d03464a30c250ac38 Mon Sep 17 00:00:00 2001 From: Mara Bos Date: Thu, 12 Jan 2023 00:31:17 +0100 Subject: [PATCH] Make core::fmt::rt::v1::Argument::new const+inline. --- library/core/src/fmt/rt/v1.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/library/core/src/fmt/rt/v1.rs b/library/core/src/fmt/rt/v1.rs index e61b89fad5d..11a50951a75 100644 --- a/library/core/src/fmt/rt/v1.rs +++ b/library/core/src/fmt/rt/v1.rs @@ -23,7 +23,8 @@ pub struct FormatSpec { } impl Argument { - pub fn new( + #[inline(always)] + pub const fn new( position: usize, fill: char, align: Alignment,