aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_def/src
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-12-11 19:57:08 +0000
committerGitHub <[email protected]>2020-12-11 19:57:08 +0000
commit91bf15a2f53629209bd13d2e46121b9be8af1f94 (patch)
treecd954234bf0ca9c8151739fe7c9565249e70c3d0 /crates/hir_def/src
parent1e4378b5406756413d0be9e89a13904bfad5ca79 (diff)
parentac19a71459765f897c3bb38ffd9a5a179e0beb02 (diff)
Merge #6834
6834: Use Attrs::docs in runnables instead of DocCommentsOwner r=kjeremy a=Veykril I figured that we should probably move as much of the doc usage to the HIR as possible hence this PR. If we should keep this AST-based feel free to close. This change does have the nice(but not really useful as I doubt anyones gonna write doc tests like these) side effect that these two doc string snippets allow being run now. ![image](https://user-images.githubusercontent.com/3757771/101945607-bf241400-3bee-11eb-96ce-ccae80028b1f.png) ![image](https://user-images.githubusercontent.com/3757771/101946375-2e9a0380-3bef-11eb-9950-e35168fdd048.png) Co-authored-by: Lukas Wirth <[email protected]>
Diffstat (limited to 'crates/hir_def/src')
-rw-r--r--crates/hir_def/src/attr.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/hir_def/src/attr.rs b/crates/hir_def/src/attr.rs
index 228d706db..ff8fb7483 100644
--- a/crates/hir_def/src/attr.rs
+++ b/crates/hir_def/src/attr.rs
@@ -32,9 +32,9 @@ impl Documentation {
32 } 32 }
33} 33}
34 34
35impl Into<String> for Documentation { 35impl From<Documentation> for String {
36 fn into(self) -> String { 36 fn from(Documentation(string): Documentation) -> Self {
37 self.0 37 string
38 } 38 }
39} 39}
40 40