Skip to content

Commit 398ab39

Browse files
committed
ArrayVecCopy: Add derive(Copy)
The final decoration on the top of the pyramid.
1 parent 2278b33 commit 398ab39

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

src/arrayvec.rs

+1
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ use crate::utils::MakeMaybeUninit;
5252
// DIRECTIVE ArrayVecCopy #[doc = "**ArrayVecCopy's only difference to [`\x41rrayVec`](crate::\x41rrayVec) is that its"]
5353
// DIRECTIVE ArrayVecCopy #[doc = "elements are constrained to be `Copy` which allows it to be `Copy` itself.** "]
5454
#[repr(C)]
55+
// DIRECTIVE ArrayVecCopy #[derive(Copy)]
5556
pub struct ArrayVec<T, const CAP: usize> {
5657
len: LenUint,
5758
// the `len` first elements of the array are initialized

src/arrayvec_copy.rs

+1
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ use crate::utils::MakeMaybeUninit;
5252
#[doc = "**ArrayVecCopy's only difference to [`\x41rrayVec`](crate::\x41rrayVec) is that its"]
5353
#[doc = "elements are constrained to be `Copy` which allows it to be `Copy` itself.** "]
5454
#[repr(C)]
55+
#[derive(Copy)]
5556
pub struct ArrayVecCopy<T: Copy, const CAP: usize> {
5657
len: LenUint,
5758
// the `len` first elements of the array are initialized

0 commit comments

Comments
 (0)