From c75d92145e3f44117848a6ed6350efdbab2a6d66 Mon Sep 17 00:00:00 2001 From: Ben-PH Date: Wed, 22 Jan 2025 14:40:17 +0100 Subject: [PATCH] auto-fix `clippy::redundant_pattern_matching` --- nexosim/src/channel/queue.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nexosim/src/channel/queue.rs b/nexosim/src/channel/queue.rs index 57747de..832a9ab 100644 --- a/nexosim/src/channel/queue.rs +++ b/nexosim/src/channel/queue.rs @@ -482,7 +482,7 @@ mod tests { assert!(matches!(c.pop(), Err(PopError::Empty))); - assert!(matches!(p.push(|b| RecycleBox::recycle(b, 42)), Ok(_))); + assert!(p.push(|b| RecycleBox::recycle(b, 42)).is_ok()); p.close(); assert_eq!(*c.pop().unwrap(), 42); @@ -494,7 +494,7 @@ mod tests { let (p, mut c) = queue(3); assert_eq!(p.is_closed(), false); - assert!(matches!(p.push(|b| RecycleBox::recycle(b, 42)), Ok(_))); + assert!(p.push(|b| RecycleBox::recycle(b, 42)).is_ok()); c.close();