aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_hir/src')
-rw-r--r--crates/ra_hir/src/docs.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/crates/ra_hir/src/docs.rs b/crates/ra_hir/src/docs.rs
index 5db72c08a..e3a755b46 100644
--- a/crates/ra_hir/src/docs.rs
+++ b/crates/ra_hir/src/docs.rs
@@ -22,6 +22,12 @@ impl Into<String> for Documentation {
22 } 22 }
23} 23}
24 24
25impl<'a> Into<String> for &'a Documentation {
26 fn into(self) -> String {
27 self.contents().into()
28 }
29}
30
25pub trait Docs { 31pub trait Docs {
26 fn docs(&self, db: &impl HirDatabase) -> Option<Documentation>; 32 fn docs(&self, db: &impl HirDatabase) -> Option<Documentation>;
27} 33}