From 14b24206c6e72a47f442de2f3cc50f9ebace267d Mon Sep 17 00:00:00 2001 From: Yotam Ofek Date: Wed, 9 Oct 2024 16:11:59 +0300 Subject: [PATCH] Upgrade zerocopy to 0.8 --- Cargo.toml | 2 +- src/lib.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 2ee6e031..fa6ce107 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -108,7 +108,7 @@ version = "1.1.3" # See: https://github.com/uuid-rs/uuid/issues/588 [dependencies.zerocopy] optional = true -version = "0.7" +version = "0.8" features = ["derive"] # Public: Used in trait impls on `Uuid` diff --git a/src/lib.rs b/src/lib.rs index eb93294e..07db5a46 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -223,7 +223,7 @@ extern crate std; extern crate core as std; #[cfg(all(uuid_unstable, feature = "zerocopy"))] -use zerocopy::{AsBytes, FromBytes, FromZeroes, Unaligned}; +use zerocopy::{IntoBytes, FromBytes, Immutable, KnownLayout, Unaligned}; mod builder; mod error; @@ -438,7 +438,7 @@ pub enum Variant { #[derive(Clone, Copy, Eq, Hash, Ord, PartialEq, PartialOrd)] #[cfg_attr( all(uuid_unstable, feature = "zerocopy"), - derive(AsBytes, FromBytes, FromZeroes, Unaligned) + derive(IntoBytes, FromBytes, KnownLayout, Immutable, Unaligned) )] #[cfg_attr( feature = "borsh",