Unnamed repository; edit this file 'description' to name the repository.
Merge pull request #21366 from ChayimFriedman2/fix-clippy
minor: Fix Clippy
| -rw-r--r-- | crates/span/src/ast_id.rs | 2 | ||||
| -rw-r--r-- | crates/span/src/map.rs | 2 | ||||
| -rw-r--r-- | crates/syntax/src/lib.rs | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/crates/span/src/ast_id.rs b/crates/span/src/ast_id.rs index da537ba990..599b3c7175 100644 --- a/crates/span/src/ast_id.rs +++ b/crates/span/src/ast_id.rs @@ -804,7 +804,7 @@ impl Drop for AstIdMap { // block on a receive _ = receiver.recv(); // then drain the entire channel - while let Ok(_) = receiver.try_recv() {} + while receiver.try_recv().is_ok() {} // and sleep for a bit std::thread::sleep(std::time::Duration::from_millis(100)); } diff --git a/crates/span/src/map.rs b/crates/span/src/map.rs index 75a1b0029c..dc7d471aa0 100644 --- a/crates/span/src/map.rs +++ b/crates/span/src/map.rs @@ -168,7 +168,7 @@ impl Drop for SpanMap { // block on a receive _ = receiver.recv(); // then drain the entire channel - while let Ok(_) = receiver.try_recv() {} + while receiver.try_recv().is_ok() {} // and sleep for a bit std::thread::sleep(std::time::Duration::from_millis(100)); } diff --git a/crates/syntax/src/lib.rs b/crates/syntax/src/lib.rs index d360195140..c510b2831e 100644 --- a/crates/syntax/src/lib.rs +++ b/crates/syntax/src/lib.rs @@ -223,7 +223,7 @@ impl<T> Drop for Parse<T> { // block on a receive _ = receiver.recv(); // then drain the entire channel - while let Ok(_) = receiver.try_recv() {} + while receiver.try_recv().is_ok() {} // and sleep for a bit std::thread::sleep(std::time::Duration::from_millis(100)); } |