@@ -926,9 +926,10 @@ impl<T: ?Sized> *mut T {
926
926
/// See [`ptr::copy`] for safety concerns and examples.
927
927
///
928
928
/// [`ptr::copy`]: crate::ptr::copy()
929
+ #[ rustc_const_unstable( feature = "const_intrinsic_copy" , issue = "80697" ) ]
929
930
#[ stable( feature = "pointer_methods" , since = "1.26.0" ) ]
930
931
#[ inline]
931
- pub unsafe fn copy_to ( self , dest : * mut T , count : usize )
932
+ pub const unsafe fn copy_to ( self , dest : * mut T , count : usize )
932
933
where
933
934
T : Sized ,
934
935
{
@@ -944,9 +945,10 @@ impl<T: ?Sized> *mut T {
944
945
/// See [`ptr::copy_nonoverlapping`] for safety concerns and examples.
945
946
///
946
947
/// [`ptr::copy_nonoverlapping`]: crate::ptr::copy_nonoverlapping()
948
+ #[ rustc_const_unstable( feature = "const_intrinsic_copy" , issue = "80697" ) ]
947
949
#[ stable( feature = "pointer_methods" , since = "1.26.0" ) ]
948
950
#[ inline]
949
- pub unsafe fn copy_to_nonoverlapping ( self , dest : * mut T , count : usize )
951
+ pub const unsafe fn copy_to_nonoverlapping ( self , dest : * mut T , count : usize )
950
952
where
951
953
T : Sized ,
952
954
{
@@ -962,9 +964,10 @@ impl<T: ?Sized> *mut T {
962
964
/// See [`ptr::copy`] for safety concerns and examples.
963
965
///
964
966
/// [`ptr::copy`]: crate::ptr::copy()
967
+ #[ rustc_const_unstable( feature = "const_intrinsic_copy" , issue = "80697" ) ]
965
968
#[ stable( feature = "pointer_methods" , since = "1.26.0" ) ]
966
969
#[ inline]
967
- pub unsafe fn copy_from ( self , src : * const T , count : usize )
970
+ pub const unsafe fn copy_from ( self , src : * const T , count : usize )
968
971
where
969
972
T : Sized ,
970
973
{
@@ -980,9 +983,10 @@ impl<T: ?Sized> *mut T {
980
983
/// See [`ptr::copy_nonoverlapping`] for safety concerns and examples.
981
984
///
982
985
/// [`ptr::copy_nonoverlapping`]: crate::ptr::copy_nonoverlapping()
986
+ #[ rustc_const_unstable( feature = "const_intrinsic_copy" , issue = "80697" ) ]
983
987
#[ stable( feature = "pointer_methods" , since = "1.26.0" ) ]
984
988
#[ inline]
985
- pub unsafe fn copy_from_nonoverlapping ( self , src : * const T , count : usize )
989
+ pub const unsafe fn copy_from_nonoverlapping ( self , src : * const T , count : usize )
986
990
where
987
991
T : Sized ,
988
992
{
0 commit comments