diff --git a/src/macros.rs b/src/macros.rs index 0bbd6aabf..f065ffd37 100644 --- a/src/macros.rs +++ b/src/macros.rs @@ -252,19 +252,17 @@ macro_rules! FLAGS { } macro_rules! STRUCT { {$(#[$attrs:meta])* nodebug struct $name:ident { $($field:ident: $ftype:ty,)+ }} => { - #[repr(C)] $(#[$attrs])* + #[repr(C)] #[derive(Copy)] $(#[$attrs])* pub struct $name { $(pub $field: $ftype,)+ } - impl Copy for $name {} impl Clone for $name { fn clone(&self) -> $name { *self } } }; {$(#[$attrs:meta])* struct $name:ident { $($field:ident: $ftype:ty,)+ }} => { - #[repr(C)] #[derive(Debug)] $(#[$attrs])* + #[repr(C)] #[derive(Debug, Copy)] $(#[$attrs])* pub struct $name { $(pub $field: $ftype,)+ } - impl Copy for $name {} impl Clone for $name { fn clone(&self) -> $name { *self } } }; }