aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
authorAndrew Chin <[email protected]>2020-05-02 00:13:52 +0100
committerAndrew Chin <[email protected]>2020-05-02 00:13:52 +0100
commit76f34a15e61fc69ccafe1ec4804712dcd3069de5 (patch)
tree11189536518c8c98c35f9c1e183e73a63a1d9edc /crates
parent3232fd5179f2e36dee69955ba8aae0463b142e67 (diff)
Improve formatting of analyzer status text
Diffstat (limited to 'crates')
-rw-r--r--crates/rust-analyzer/src/main_loop/handlers.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/rust-analyzer/src/main_loop/handlers.rs b/crates/rust-analyzer/src/main_loop/handlers.rs
index 0f623949e..574e070fc 100644
--- a/crates/rust-analyzer/src/main_loop/handlers.rs
+++ b/crates/rust-analyzer/src/main_loop/handlers.rs
@@ -46,11 +46,11 @@ use crate::{
46pub fn handle_analyzer_status(world: WorldSnapshot, _: ()) -> Result<String> { 46pub fn handle_analyzer_status(world: WorldSnapshot, _: ()) -> Result<String> {
47 let _p = profile("handle_analyzer_status"); 47 let _p = profile("handle_analyzer_status");
48 let mut buf = world.status(); 48 let mut buf = world.status();
49 format_to!(buf, "\n\nrequests:"); 49 format_to!(buf, "\n\nrequests:\n");
50 let requests = world.latest_requests.read(); 50 let requests = world.latest_requests.read();
51 for (is_last, r) in requests.iter() { 51 for (is_last, r) in requests.iter() {
52 let mark = if is_last { "*" } else { " " }; 52 let mark = if is_last { "*" } else { " " };
53 format_to!(buf, "{}{:4} {:<36}{}ms", mark, r.id, r.method, r.duration.as_millis()); 53 format_to!(buf, "{}{:4} {:<36}{}ms\n", mark, r.id, r.method, r.duration.as_millis());
54 } 54 }
55 Ok(buf) 55 Ok(buf)
56} 56}