more clippy fixes

This commit is contained in:
Milo
2021-10-16 12:32:55 +01:00
parent 3c468ab2fc
commit 35e5daacc3
19 changed files with 46 additions and 52 deletions

View File

@@ -77,7 +77,7 @@ impl GlobalState {
return;
}
let percentage = fraction.map(|f| {
assert!(0.0 <= f && f <= 1.0);
assert!((0.0..=1.0).contains(&f));
(f * 100.0) as u32
});
let token = lsp_types::ProgressToken::String(format!("rustAnalyzer/{}", title));