From 9dcab4ed30527707fb53b887d5ffcb87cb3d3e79 Mon Sep 17 00:00:00 2001 From: Ivan Enderlin Date: Mon, 18 Mar 2024 12:57:18 +0100 Subject: [PATCH] feat(sdk): `ItemPosition` has the copy semantics. This patch implements `Copy` and `Clone` for `ItemPosition`. --- crates/matrix-sdk/src/event_cache/linked_chunk.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/matrix-sdk/src/event_cache/linked_chunk.rs b/crates/matrix-sdk/src/event_cache/linked_chunk.rs index 7490e0dad..5810b9071 100644 --- a/crates/matrix-sdk/src/event_cache/linked_chunk.rs +++ b/crates/matrix-sdk/src/event_cache/linked_chunk.rs @@ -583,7 +583,7 @@ impl ChunkIdentifier { /// /// It's a pair of a chunk position and an item index. `(…, 0)` represents /// the last item in the chunk. -#[derive(Debug, PartialEq)] +#[derive(Copy, Clone, Debug, PartialEq)] pub struct ItemPosition(ChunkIdentifier, usize); impl ItemPosition {