Skip to content

Commit b5d5682

Browse files
committed
Make core::mem::copy const
1 parent 88a1922 commit b5d5682

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/core/src/mem/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1005,7 +1005,7 @@ pub fn drop<T>(_x: T) {}
10051005
/// ```
10061006
#[inline]
10071007
#[unstable(feature = "mem_copy_fn", issue = "98262")]
1008-
pub fn copy<T: Copy>(x: &T) -> T {
1008+
pub const fn copy<T: Copy>(x: &T) -> T {
10091009
*x
10101010
}
10111011

0 commit comments

Comments
 (0)