diff options
author | Lars Wirzenius <liw@liw.fi> | 2020-12-23 19:35:23 +0200 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2020-12-23 19:35:23 +0200 |
commit | 345c5d822776ef78e594c2365d8bfd39202952e0 (patch) | |
tree | 37fbdb673eb03c63c8a909540a885d82d0225357 /src/chunk.rs | |
parent | 4128b937a6bd1ea3944a6a7f00930d40f27f2d2a (diff) | |
download | obnam2-345c5d822776ef78e594c2365d8bfd39202952e0.tar.gz |
refactor: use a struct instead of a tuple
It seems this is more idiomatic in Rust.
Diffstat (limited to 'src/chunk.rs')
-rw-r--r-- | src/chunk.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/chunk.rs b/src/chunk.rs index e1358ee..7fdeccb 100644 --- a/src/chunk.rs +++ b/src/chunk.rs @@ -8,7 +8,7 @@ use std::default::Default; /// /// A chunk also contains its associated metadata, except its /// identifier. -#[derive(Debug, Serialize, Deserialize)] +#[derive(Debug, Clone, Serialize, Deserialize)] pub struct DataChunk { data: Vec<u8>, } |