Enable clippy::useless_conversion
(#8767)
This PR enables the [`clippy::useless_conversion`](https://rust-lang.github.io/rust-clippy/master/index.html#/useless_conversion) rule and fixes the outstanding violations. Release Notes: - N/A
This commit is contained in:
parent
20d133322a
commit
fe04f69caf
30 changed files with 53 additions and 66 deletions
|
@ -221,7 +221,7 @@ impl Dock {
|
|||
return;
|
||||
};
|
||||
if panel.is_zoomed(cx) {
|
||||
workspace.zoomed = Some(panel.to_any().downgrade().into());
|
||||
workspace.zoomed = Some(panel.to_any().downgrade());
|
||||
workspace.zoomed_position = Some(position);
|
||||
} else {
|
||||
workspace.zoomed = None;
|
||||
|
|
|
@ -899,7 +899,7 @@ impl Pane {
|
|||
if not_shown_files == 1 {
|
||||
file_names.push(".. 1 file not shown".into());
|
||||
} else {
|
||||
file_names.push(format!(".. {} files not shown", not_shown_files).into());
|
||||
file_names.push(format!(".. {} files not shown", not_shown_files));
|
||||
}
|
||||
}
|
||||
(
|
||||
|
|
|
@ -2961,7 +2961,7 @@ impl Workspace {
|
|||
})?;
|
||||
|
||||
let Some(id) = view.id.clone() else {
|
||||
return Err(anyhow!("no id for view")).into();
|
||||
return Err(anyhow!("no id for view"));
|
||||
};
|
||||
let id = ViewId::from_proto(id)?;
|
||||
|
||||
|
@ -3744,7 +3744,7 @@ fn open_items(
|
|||
|
||||
let tasks = tasks.collect::<Vec<_>>();
|
||||
|
||||
let tasks = futures::future::join_all(tasks.into_iter());
|
||||
let tasks = futures::future::join_all(tasks);
|
||||
for (ix, path_open_result) in tasks.await.into_iter().flatten() {
|
||||
opened_items[ix] = Some(path_open_result);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue