diff options
| author | Oli Scherer <github35764891676564198441@oli-obk.de> | 2025-09-13 07:09:16 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-09-13 07:09:16 +0000 |
| commit | 8ade141c46ea74b7988e48d26f83b2d24d60a991 (patch) | |
| tree | 2f810c44d18e82c7d160925dc49c157acbae9116 /library/core/src/tuple.rs | |
| parent | fc7eb3c28d2be162dd32951811ce7852bb1a2f6a (diff) | |
| parent | 520e45a538a6c047c77785f09fdead3842b7b7ba (diff) | |
| download | rust-8ade141c46ea74b7988e48d26f83b2d24d60a991.tar.gz rust-8ade141c46ea74b7988e48d26f83b2d24d60a991.zip | |
Merge pull request #4584 from rust-lang/rustup-2025-09-13
Automatic Rustup
Diffstat (limited to 'library/core/src/tuple.rs')
| -rw-r--r-- | library/core/src/tuple.rs | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/library/core/src/tuple.rs b/library/core/src/tuple.rs index 2cdee1803a9..3892f831076 100644 --- a/library/core/src/tuple.rs +++ b/library/core/src/tuple.rs @@ -23,7 +23,8 @@ macro_rules! tuple_impls { maybe_tuple_doc! { $($T)+ @ #[stable(feature = "rust1", since = "1.0.0")] - impl<$($T: PartialEq),+> PartialEq for ($($T,)+) { + #[rustc_const_unstable(feature = "const_cmp", issue = "143800")] + impl<$($T: [const] PartialEq),+> const PartialEq for ($($T,)+) { #[inline] fn eq(&self, other: &($($T,)+)) -> bool { $( ${ignore($T)} self.${index()} == other.${index()} )&&+ @@ -38,7 +39,8 @@ macro_rules! tuple_impls { maybe_tuple_doc! { $($T)+ @ #[stable(feature = "rust1", since = "1.0.0")] - impl<$($T: Eq),+> Eq for ($($T,)+) + #[rustc_const_unstable(feature = "const_cmp", issue = "143800")] + impl<$($T: [const] Eq),+> const Eq for ($($T,)+) {} } @@ -66,7 +68,8 @@ macro_rules! tuple_impls { maybe_tuple_doc! { $($T)+ @ #[stable(feature = "rust1", since = "1.0.0")] - impl<$($T: PartialOrd),+> PartialOrd for ($($T,)+) + #[rustc_const_unstable(feature = "const_cmp", issue = "143800")] + impl<$($T: [const] PartialOrd),+> const PartialOrd for ($($T,)+) { #[inline] fn partial_cmp(&self, other: &($($T,)+)) -> Option<Ordering> { @@ -110,7 +113,8 @@ macro_rules! tuple_impls { maybe_tuple_doc! { $($T)+ @ #[stable(feature = "rust1", since = "1.0.0")] - impl<$($T: Ord),+> Ord for ($($T,)+) + #[rustc_const_unstable(feature = "const_cmp", issue = "143800")] + impl<$($T: [const] Ord),+> const Ord for ($($T,)+) { #[inline] fn cmp(&self, other: &($($T,)+)) -> Ordering { |
