diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-10-20 10:46:43 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2020-10-20 10:46:43 +0100 |
commit | 4c00bdea675d33d578cff1c0d7cc3967303e6653 (patch) | |
tree | bc1cd5b714e9566e2c87f33582d8c587cf46f6c0 /crates/hir_def/src | |
parent | 378dd90bab65fa6df078444c3932118105a460b8 (diff) | |
parent | b8a74e03708819c04862005ad0a91757dd63d654 (diff) |
Merge #6266
6266: Generate diagnostics docs r=matklad a=popzxc
Resolves #6215
Co-authored-by: Igor Aleksanov <[email protected]>
Diffstat (limited to 'crates/hir_def/src')
-rw-r--r-- | crates/hir_def/src/diagnostics.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/crates/hir_def/src/diagnostics.rs b/crates/hir_def/src/diagnostics.rs index 001b3c5db..fcfbbbad3 100644 --- a/crates/hir_def/src/diagnostics.rs +++ b/crates/hir_def/src/diagnostics.rs | |||
@@ -7,6 +7,9 @@ use syntax::{ast, AstPtr, SyntaxNodePtr}; | |||
7 | 7 | ||
8 | use hir_expand::{HirFileId, InFile}; | 8 | use hir_expand::{HirFileId, InFile}; |
9 | 9 | ||
10 | // Diagnostic: unresolved-module | ||
11 | // | ||
12 | // This diagnostic is triggered if rust-analyzer is unable to discover referred module. | ||
10 | #[derive(Debug)] | 13 | #[derive(Debug)] |
11 | pub struct UnresolvedModule { | 14 | pub struct UnresolvedModule { |
12 | pub file: HirFileId, | 15 | pub file: HirFileId, |
@@ -29,6 +32,9 @@ impl Diagnostic for UnresolvedModule { | |||
29 | } | 32 | } |
30 | } | 33 | } |
31 | 34 | ||
35 | // Diagnostic: unresolved-extern-crate | ||
36 | // | ||
37 | // This diagnostic is triggered if rust-analyzer is unable to discover referred extern crate. | ||
32 | #[derive(Debug)] | 38 | #[derive(Debug)] |
33 | pub struct UnresolvedExternCrate { | 39 | pub struct UnresolvedExternCrate { |
34 | pub file: HirFileId, | 40 | pub file: HirFileId, |
@@ -50,6 +56,9 @@ impl Diagnostic for UnresolvedExternCrate { | |||
50 | } | 56 | } |
51 | } | 57 | } |
52 | 58 | ||
59 | // Diagnostic: unresolved-import | ||
60 | // | ||
61 | // This diagnostic is triggered if rust-analyzer is unable to discover imported module. | ||
53 | #[derive(Debug)] | 62 | #[derive(Debug)] |
54 | pub struct UnresolvedImport { | 63 | pub struct UnresolvedImport { |
55 | pub file: HirFileId, | 64 | pub file: HirFileId, |