From 9e4bcda17b97028e3303b9d603bbe6aef2ef8e2b Mon Sep 17 00:00:00 2001 From: Jade Ellis Date: Mon, 10 Nov 2025 19:41:56 +0000 Subject: [PATCH] style(clippy): Make the event graph generic over the hasher --- src/core/matrix/state_res/mod.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/core/matrix/state_res/mod.rs b/src/core/matrix/state_res/mod.rs index 0e0b5ec5..11c754e9 100644 --- a/src/core/matrix/state_res/mod.rs +++ b/src/core/matrix/state_res/mod.rs @@ -421,8 +421,8 @@ where /// `key_fn` is used as to obtain the power level and age of an event for /// breaking ties (together with the event ID). #[tracing::instrument(level = "debug", skip_all)] -pub async fn lexicographical_topological_sort( - graph: &HashMap>, +pub async fn lexicographical_topological_sort( + graph: &HashMap, S>, key_fn: &F, ) -> Result> where @@ -430,6 +430,7 @@ where Fut: Future> + Send, Id: Borrow + Clone + Eq + Hash + Ord + Send + Sync, Hasher: BuildHasher + Default + Clone + Send + Sync, + S: BuildHasher + Clone + Send + Sync, { #[derive(PartialEq, Eq)] struct TieBreaker<'a, Id> {