@@ -92,7 +92,7 @@ impl<T: ?Sized> *const T {
9292/// } 
9393/// ``` 
9494#[ unstable( feature = "set_ptr_value" ,  issue = "75091" ) ]  
95-     #[ rustc_const_unstable ( feature = "set_ptr_value " ,  issue  = "75091 " ) ]  
95+     #[ rustc_const_stable ( feature = "ptr_metadata_const " ,  since  = "CURRENT_RUSTC_VERSION " ) ]  
9696    #[ must_use = "returns a new pointer rather than modifying its argument" ]  
9797    #[ inline]  
9898    pub  const  fn  with_metadata_of < U > ( self ,  meta :  * const  U )  -> * const  U 
@@ -412,7 +412,6 @@ impl<T: ?Sized> *const T {
412412    #[ inline( always) ]  
413413    #[ stable( feature = "pointer_byte_offsets" ,  since = "1.75.0" ) ]  
414414    #[ rustc_const_stable( feature = "const_pointer_byte_offsets" ,  since = "1.75.0" ) ]  
415-     #[ rustc_allow_const_fn_unstable( set_ptr_value) ]  
416415    #[ cfg_attr( miri,  track_caller) ]   // even without panics, this helps for Miri backtraces 
417416    pub  const  unsafe  fn  byte_offset ( self ,  count :  isize )  -> Self  { 
418417        // SAFETY: the caller must uphold the safety contract for `offset`. 
@@ -495,7 +494,6 @@ impl<T: ?Sized> *const T {
495494    #[ inline( always) ]  
496495    #[ stable( feature = "pointer_byte_offsets" ,  since = "1.75.0" ) ]  
497496    #[ rustc_const_stable( feature = "const_pointer_byte_offsets" ,  since = "1.75.0" ) ]  
498-     #[ rustc_allow_const_fn_unstable( set_ptr_value) ]  
499497    pub  const  fn  wrapping_byte_offset ( self ,  count :  isize )  -> Self  { 
500498        self . cast :: < u8 > ( ) . wrapping_offset ( count) . with_metadata_of ( self ) 
501499    } 
@@ -645,7 +643,6 @@ impl<T: ?Sized> *const T {
645643#[ inline( always) ]  
646644    #[ stable( feature = "pointer_byte_offsets" ,  since = "1.75.0" ) ]  
647645    #[ rustc_const_stable( feature = "const_pointer_byte_offsets" ,  since = "1.75.0" ) ]  
648-     #[ rustc_allow_const_fn_unstable( set_ptr_value) ]  
649646    #[ cfg_attr( miri,  track_caller) ]   // even without panics, this helps for Miri backtraces 
650647    pub  const  unsafe  fn  byte_offset_from < U :  ?Sized > ( self ,  origin :  * const  U )  -> isize  { 
651648        // SAFETY: the caller must uphold the safety contract for `offset_from`. 
@@ -873,7 +870,6 @@ impl<T: ?Sized> *const T {
873870    #[ inline( always) ]  
874871    #[ stable( feature = "pointer_byte_offsets" ,  since = "1.75.0" ) ]  
875872    #[ rustc_const_stable( feature = "const_pointer_byte_offsets" ,  since = "1.75.0" ) ]  
876-     #[ rustc_allow_const_fn_unstable( set_ptr_value) ]  
877873    #[ cfg_attr( miri,  track_caller) ]   // even without panics, this helps for Miri backtraces 
878874    pub  const  unsafe  fn  byte_add ( self ,  count :  usize )  -> Self  { 
879875        // SAFETY: the caller must uphold the safety contract for `add`. 
@@ -956,7 +952,6 @@ impl<T: ?Sized> *const T {
956952    #[ inline( always) ]  
957953    #[ stable( feature = "pointer_byte_offsets" ,  since = "1.75.0" ) ]  
958954    #[ rustc_const_stable( feature = "const_pointer_byte_offsets" ,  since = "1.75.0" ) ]  
959-     #[ rustc_allow_const_fn_unstable( set_ptr_value) ]  
960955    #[ cfg_attr( miri,  track_caller) ]   // even without panics, this helps for Miri backtraces 
961956    pub  const  unsafe  fn  byte_sub ( self ,  count :  usize )  -> Self  { 
962957        // SAFETY: the caller must uphold the safety contract for `sub`. 
@@ -1039,7 +1034,6 @@ impl<T: ?Sized> *const T {
10391034    #[ inline( always) ]  
10401035    #[ stable( feature = "pointer_byte_offsets" ,  since = "1.75.0" ) ]  
10411036    #[ rustc_const_stable( feature = "const_pointer_byte_offsets" ,  since = "1.75.0" ) ]  
1042-     #[ rustc_allow_const_fn_unstable( set_ptr_value) ]  
10431037    pub  const  fn  wrapping_byte_add ( self ,  count :  usize )  -> Self  { 
10441038        self . cast :: < u8 > ( ) . wrapping_add ( count) . with_metadata_of ( self ) 
10451039    } 
@@ -1120,7 +1114,6 @@ impl<T: ?Sized> *const T {
11201114    #[ inline( always) ]  
11211115    #[ stable( feature = "pointer_byte_offsets" ,  since = "1.75.0" ) ]  
11221116    #[ rustc_const_stable( feature = "const_pointer_byte_offsets" ,  since = "1.75.0" ) ]  
1123-     #[ rustc_allow_const_fn_unstable( set_ptr_value) ]  
11241117    pub  const  fn  wrapping_byte_sub ( self ,  count :  usize )  -> Self  { 
11251118        self . cast :: < u8 > ( ) . wrapping_sub ( count) . with_metadata_of ( self ) 
11261119    } 
@@ -1554,7 +1547,6 @@ impl<T> *const [T] {
15541547#[ inline]  
15551548    #[ stable( feature = "slice_ptr_len" ,  since = "1.79.0" ) ]  
15561549    #[ rustc_const_stable( feature = "const_slice_ptr_len" ,  since = "1.79.0" ) ]  
1557-     #[ rustc_allow_const_fn_unstable( ptr_metadata) ]  
15581550    pub  const  fn  len ( self )  -> usize  { 
15591551        metadata ( self ) 
15601552    } 
0 commit comments