From 1caaafdce7871bc2816c9f42a14fd9262eda4037 Mon Sep 17 00:00:00 2001 From: Simon Sapin Date: Fri, 20 Apr 2018 13:56:07 +0200 Subject: [PATCH] Implement Copy for std::alloc::Layout Fixes https://github.com/rust-lang/rust/issues/48458 --- src/libcore/alloc.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libcore/alloc.rs b/src/libcore/alloc.rs index f08baa3dd71c3..54440eaa40f91 100644 --- a/src/libcore/alloc.rs +++ b/src/libcore/alloc.rs @@ -63,7 +63,7 @@ fn size_align() -> (usize, usize) { /// requests have positive size. A caller to the `Alloc::alloc` /// method must either ensure that conditions like this are met, or /// use specific allocators with looser requirements.) -#[derive(Clone, Debug, PartialEq, Eq)] +#[derive(Copy, Clone, Debug, PartialEq, Eq)] pub struct Layout { // size of the requested block of memory, measured in bytes. size: usize,