aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide/src/display.rs
diff options
context:
space:
mode:
authorGalilée 'Bill' Enguehard <[email protected]>2020-05-22 18:04:39 +0100
committerGalilée 'Bill' Enguehard <[email protected]>2020-05-22 18:04:39 +0100
commit5043c9ce9c9d07263305ef0e560b8ce506593748 (patch)
tree7391b9066d1adc0262205f0b1aa067833734dfe6 /crates/ra_ide/src/display.rs
parent7fece3bdd2450c0807f7dd742239cae95f0cc65e (diff)
Modify hover info to show module path separated by a line
Diffstat (limited to 'crates/ra_ide/src/display.rs')
-rw-r--r--crates/ra_ide/src/display.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_ide/src/display.rs b/crates/ra_ide/src/display.rs
index cb3508086..323505ef6 100644
--- a/crates/ra_ide/src/display.rs
+++ b/crates/ra_ide/src/display.rs
@@ -79,14 +79,14 @@ pub(crate) fn rust_code_markup_with_doc(
79 doc: Option<&str>, 79 doc: Option<&str>,
80 mod_path: Option<&str>, 80 mod_path: Option<&str>,
81) -> String { 81) -> String {
82 let mut buf = "```rust\n".to_owned(); 82 let mut buf = "".to_owned();
83 83
84 if let Some(mod_path) = mod_path { 84 if let Some(mod_path) = mod_path {
85 if !mod_path.is_empty() { 85 if !mod_path.is_empty() {
86 format_to!(buf, "{}\n\n", mod_path); 86 format_to!(buf, "{}\n___\n", mod_path);
87 } 87 }
88 } 88 }
89 format_to!(buf, "{}\n```", code); 89 format_to!(buf, "```rust\n\n{}\n```", code);
90 90
91 if let Some(doc) = doc { 91 if let Some(doc) = doc {
92 format_to!(buf, "\n\n{}", doc); 92 format_to!(buf, "\n\n{}", doc);