mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 22:31:43 +00:00
remove unneeded ifs
This commit is contained in:
parent
2e60908fde
commit
443d2164ef
1 changed files with 1 additions and 9 deletions
|
@ -42,15 +42,7 @@ pub(crate) fn status(db: &RootDatabase, file_id: Option<FileId>) -> String {
|
|||
format_to!(buf, "{} (Macros)\n", macro_syntax_tree_stats(db));
|
||||
format_to!(buf, "{} in total\n", memory_usage());
|
||||
if env::var("RA_COUNT").is_ok() {
|
||||
format_to!(
|
||||
buf,
|
||||
"\nCounts:\n{}",
|
||||
if count.to_string().contains("all counts are zero") {
|
||||
String::from("All counts are zero\n")
|
||||
} else {
|
||||
count.to_string()
|
||||
}
|
||||
);
|
||||
format_to!(buf, "\nCounts:\n{}", count.to_string());
|
||||
}
|
||||
|
||||
if let Some(file_id) = file_id {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue