about summary refs log tree commit diff
path: root/library/core/src/intrinsics
diff options
context:
space:
mode:
authorNathaniel McCallum <nathaniel@mccallum.life>2025-08-31 22:26:10 -0400
committerLeón Orell Valerian Liehr <me@fmease.dev>2025-09-06 04:35:52 +0200
commit00fcb14e4e6e4fb28fde6a286fd9ac30a2d457c7 (patch)
tree00d1276f71461788745df2b5cc15af546d3d3e76 /library/core/src/intrinsics
parent6c699a37235700ab749e3f14147fe41d49c056e8 (diff)
downloadrust-00fcb14e4e6e4fb28fde6a286fd9ac30a2d457c7.tar.gz
rust-00fcb14e4e6e4fb28fde6a286fd9ac30a2d457c7.zip
clean up some old const trait impl syntax
Diffstat (limited to 'library/core/src/intrinsics')
-rw-r--r--library/core/src/intrinsics/fallback.rs9
1 files changed, 3 insertions, 6 deletions
diff --git a/library/core/src/intrinsics/fallback.rs b/library/core/src/intrinsics/fallback.rs
index 96928325328..932537f2581 100644
--- a/library/core/src/intrinsics/fallback.rs
+++ b/library/core/src/intrinsics/fallback.rs
@@ -7,9 +7,8 @@
 )]
 #![allow(missing_docs)]
 
-#[const_trait]
 #[rustc_const_unstable(feature = "core_intrinsics_fallbacks", issue = "none")]
-pub trait CarryingMulAdd: Copy + 'static {
+pub const trait CarryingMulAdd: Copy + 'static {
     type Unsigned: Copy + 'static;
     fn carrying_mul_add(
         self,
@@ -111,9 +110,8 @@ impl const CarryingMulAdd for i128 {
     }
 }
 
-#[const_trait]
 #[rustc_const_unstable(feature = "core_intrinsics_fallbacks", issue = "none")]
-pub trait DisjointBitOr: Copy + 'static {
+pub const trait DisjointBitOr: Copy + 'static {
     /// See [`super::disjoint_bitor`]; we just need the trait indirection to handle
     /// different types since calling intrinsics with generics doesn't work.
     unsafe fn disjoint_bitor(self, other: Self) -> Self;
@@ -149,9 +147,8 @@ impl_disjoint_bitor! {
     i8, i16, i32, i64, i128, isize,
 }
 
-#[const_trait]
 #[rustc_const_unstable(feature = "core_intrinsics_fallbacks", issue = "none")]
-pub trait FunnelShift: Copy + 'static {
+pub const trait FunnelShift: Copy + 'static {
     /// See [`super::unchecked_funnel_shl`]; we just need the trait indirection to handle
     /// different types since calling intrinsics with generics doesn't work.
     unsafe fn unchecked_funnel_shl(self, rhs: Self, shift: u32) -> Self;