aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_analysis/src/imp.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_analysis/src/imp.rs')
-rw-r--r--crates/ra_analysis/src/imp.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/crates/ra_analysis/src/imp.rs b/crates/ra_analysis/src/imp.rs
index 07357fc84..99bcf0666 100644
--- a/crates/ra_analysis/src/imp.rs
+++ b/crates/ra_analysis/src/imp.rs
@@ -326,7 +326,9 @@ impl AnalysisImpl {
326 pub fn doc_text_for(&self, file_id: FileId, symbol: FileSymbol) -> Cancelable<Option<String>> { 326 pub fn doc_text_for(&self, file_id: FileId, symbol: FileSymbol) -> Cancelable<Option<String>> {
327 let file = self.db.source_file(file_id); 327 let file = self.db.source_file(file_id);
328 let result = match (symbol.description(&file), symbol.docs(&file)) { 328 let result = match (symbol.description(&file), symbol.docs(&file)) {
329 (Some(desc), Some(docs)) => Some("```rust\n".to_string() + &*desc + "\n```\n\n" + &*docs), 329 (Some(desc), Some(docs)) => {
330 Some("```rust\n".to_string() + &*desc + "\n```\n\n" + &*docs)
331 }
330 (Some(desc), None) => Some("```rust\n".to_string() + &*desc + "\n```"), 332 (Some(desc), None) => Some("```rust\n".to_string() + &*desc + "\n```"),
331 (None, Some(docs)) => Some(docs), 333 (None, Some(docs)) => Some(docs),
332 _ => None, 334 _ => None,