From 21e43a21de05c62867a6dd8dbe12444fbb1f58da Mon Sep 17 00:00:00 2001 From: eax-ebx <61050197+eaxecx@users.noreply.github.com> Date: Mon, 4 Dec 2023 21:36:11 +0100 Subject: [PATCH] feat: derive Copy and Clone for Qualifier (#69) I ran into a problem, where I needed to copy the `qual` field from an ACLEntry instance (which is borrowed), but compiler didn't allow me to do this, because the Qualifier enum is not copyable, and in my case move isn't possible and desirable. Deriving the Copy and Clone traits fixes this. --- src/entry.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/entry.rs b/src/entry.rs index b69d481..7ffea93 100644 --- a/src/entry.rs +++ b/src/entry.rs @@ -7,7 +7,7 @@ use acl_sys::{ use std::ptr::null_mut; /// The subject of a permission grant. -#[derive(Debug, PartialEq, Eq)] +#[derive(Copy, Clone, Debug, PartialEq, Eq)] pub enum Qualifier { /// Unrecognized/corrupt entries Undefined,