about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMaybe Waffle <waffle.lapkin@gmail.com>2023-02-22 17:59:49 +0000
committerMaybe Waffle <waffle.lapkin@gmail.com>2023-04-27 15:46:23 +0000
commit81a2b856c8e6336f01831108924004f582ad59d0 (patch)
tree053cb56101138d5244cc58636f9b94c69ccb909f
parentc8844e1337f1304d06417a712110abbd3a2beb95 (diff)
downloadrust-81a2b856c8e6336f01831108924004f582ad59d0.tar.gz
rust-81a2b856c8e6336f01831108924004f582ad59d0.zip
Remove `feature(const_param_ty_trait)`, use `adt_const_params` instead
-rw-r--r--library/core/src/marker.rs30
-rw-r--r--tests/ui/const-generics/const_patam_ty_impl_bad_field.rs3
-rw-r--r--tests/ui/const-generics/const_patam_ty_impl_bad_field.stderr2
3 files changed, 18 insertions, 17 deletions
diff --git a/library/core/src/marker.rs b/library/core/src/marker.rs
index ff8653c0820..24e95aed27e 100644
--- a/library/core/src/marker.rs
+++ b/library/core/src/marker.rs
@@ -914,36 +914,36 @@ pub trait PointerLike {}
 
 /// A marker for types which can be used as types of `const` generic parameters.
 #[cfg_attr(not(bootstrap), lang = "const_param_ty")]
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 #[rustc_on_unimplemented(message = "`{Self}` can't be used as a const parameter type")]
 pub trait ConstParamTy: StructuralEq {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for usize {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for u8 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for u16 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for u32 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for u64 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for u128 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for isize {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for i8 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for i16 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for i32 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for i64 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for i128 {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for bool {}
-#[unstable(feature = "const_param_ty_trait", issue = "none")]
+#[unstable(feature = "adt_const_params", issue = "95174")]
 impl ConstParamTy for char {}
 
 /// Implementations of `Copy` for primitive types.
diff --git a/tests/ui/const-generics/const_patam_ty_impl_bad_field.rs b/tests/ui/const-generics/const_patam_ty_impl_bad_field.rs
index 2cfccb68b0e..3d2d99b9d38 100644
--- a/tests/ui/const-generics/const_patam_ty_impl_bad_field.rs
+++ b/tests/ui/const-generics/const_patam_ty_impl_bad_field.rs
@@ -1,4 +1,5 @@
-#![feature(const_param_ty_trait)]
+#![allow(incomplete_features)]
+#![feature(adt_const_params)]
 
 #[derive(PartialEq, Eq)]
 struct NotParam;
diff --git a/tests/ui/const-generics/const_patam_ty_impl_bad_field.stderr b/tests/ui/const-generics/const_patam_ty_impl_bad_field.stderr
index dd150deffc2..273845b1668 100644
--- a/tests/ui/const-generics/const_patam_ty_impl_bad_field.stderr
+++ b/tests/ui/const-generics/const_patam_ty_impl_bad_field.stderr
@@ -1,5 +1,5 @@
 error[E0204]: the trait `ConstParamTy` may not be implemented for this type
-  --> $DIR/const_patam_ty_impl_bad_field.rs:9:36
+  --> $DIR/const_patam_ty_impl_bad_field.rs:10:36
    |
 LL | struct CantParam(NotParam);
    |                  -------- this field does not implement `ConstParamTy`