Skip to content

Commit 85de5f1

Browse files
committed
Updated dependencies; mmap feature gate
1 parent 06cef35 commit 85de5f1

File tree

4 files changed

+16
-10
lines changed

4 files changed

+16
-10
lines changed

CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Change Log
22

3+
## [0.6.3] - 2025-02-07
4+
5+
### New
6+
7+
* Memory-mapping can be disabled using the `mmap` default feature.
8+
39
## [0.6.2] - 2025-02-07
410

511
### Improved

epserde/Cargo.toml

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "epserde"
33
authors = ["Tommaso Fontana <[email protected]>", "Sebastiano Vigna <[email protected]>"]
44
description = "ε-serde is an ε-copy (i.e., almost zero-copy) serialization/deserialization framework"
5-
version = "0.6.2"
5+
version = "0.6.3"
66
edition = "2021"
77
repository = "https://github.com/vigna/epserde-rs/"
88
license = "Apache-2.0 OR LGPL-2.1-or-later"
@@ -16,10 +16,10 @@ xxhash-rust = {version="0.8.8", default-features=false, features=["xxh3"] }
1616
epserde-derive = { version="=0.6.0", optional = true }
1717
#epserde-derive = { path="../epserde-derive", optional = true }
1818
anyhow = "1.0.79"
19-
thiserror = "1.0.63"
20-
sealed = "0.5.0"
19+
thiserror = "2.0.11"
20+
sealed = "0.6.0"
2121
maligned = "0.2.1"
22-
common_traits = "0.10.2"
22+
common_traits = "0.11.2"
2323
mem_dbg = { version="0.2.4", features=["maligned", "derive"], default-features=false }
2424

2525
[features]

epserde/src/deser/mod.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ pub trait Deserialize: TypeHash + ReprHash + DeserializeInner {
127127
///
128128
/// The behavior of `mmap()` can be modified by passing some [`Flags`]; otherwise,
129129
/// just pass `Flags::empty()`.
130-
///
130+
///
131131
/// Requires the `mmap` feature.
132132
#[cfg(feature = "mmap")]
133133
#[allow(clippy::uninit_vec)]
@@ -174,7 +174,7 @@ pub trait Deserialize: TypeHash + ReprHash + DeserializeInner {
174174
///
175175
/// The behavior of `mmap()` can be modified by passing some [`Flags`]; otherwise,
176176
/// just pass `Flags::empty()`.
177-
///
177+
///
178178
/// Requires the `mmap` feature.
179179
#[cfg(feature = "mmap")]
180180
#[allow(clippy::uninit_vec)]
@@ -350,14 +350,14 @@ pub enum Error {
350350
#[error("Alignment error. Most likely you are deserializing from a memory region with insufficient alignment.")]
351351
/// Some fields are not properly aligned.
352352
AlignmentError,
353-
#[error("Major version mismatch. Expected {} but got {0}.", VERSION.0)]
353+
#[error("Major version mismatch. Expected {major} but got {0}.", major = VERSION.0)]
354354
/// The file was serialized with a version of ε-serde that is not compatible.
355355
MajorVersionMismatch(u16),
356-
#[error("Minor version mismatch. Expected {} but got {0}.", VERSION.1)]
356+
#[error("Minor version mismatch. Expected {minor} but got {0}.", minor = VERSION.1)]
357357
/// The file was serialized with a compatible, but too new version of ε-serde
358358
/// so we might be missing features.
359359
MinorVersionMismatch(u16),
360-
#[error("The file was serialized on an architecture where a usize has size {0}, but on the current architecture it has size {}.", core::mem::size_of::<usize>())]
360+
#[error("The file was serialized on an architecture where a usize has size {0}, but on the current architecture it has size {size}.", size = core::mem::size_of::<usize>())]
361361
/// The the `pointer_width` of the serialized file is different from the
362362
/// `pointer_width` of the current architecture.
363363
/// For example, the file was serialized on a 64-bit machine and we are trying to

epserde/tests/test_memcase.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ struct Data<A> {
2323

2424
type Person = PersonVec<Vec<usize>, Data<Vec<u16>>>;
2525

26-
#[cfg(feature="mmap")]
26+
#[cfg(feature = "mmap")]
2727
#[test]
2828
fn test_mem_case() {
2929
// Create a new value to serialize

0 commit comments

Comments
 (0)