summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/len_without_is_empty.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/tools/clippy/tests/ui/len_without_is_empty.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/clippy/tests/ui/len_without_is_empty.rs b/src/tools/clippy/tests/ui/len_without_is_empty.rs
index 1e938e72b..78397c2af 100644
--- a/src/tools/clippy/tests/ui/len_without_is_empty.rs
+++ b/src/tools/clippy/tests/ui/len_without_is_empty.rs
@@ -274,7 +274,7 @@ impl AsyncLen {
}
pub async fn len(&self) -> usize {
- if self.async_task().await { 0 } else { 1 }
+ usize::from(!self.async_task().await)
}
pub async fn is_empty(&self) -> bool {