aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_def/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_def/src')
-rw-r--r--crates/hir_def/src/diagnostics.rs6
-rw-r--r--crates/hir_def/src/nameres.rs2
2 files changed, 4 insertions, 4 deletions
diff --git a/crates/hir_def/src/diagnostics.rs b/crates/hir_def/src/diagnostics.rs
index 53cf1aca1..ad3b6bf26 100644
--- a/crates/hir_def/src/diagnostics.rs
+++ b/crates/hir_def/src/diagnostics.rs
@@ -91,14 +91,14 @@ impl Diagnostic for UnresolvedImport {
91// 91//
92// This diagnostic is shown for code with inactive `#[cfg]` attributes. 92// This diagnostic is shown for code with inactive `#[cfg]` attributes.
93#[derive(Debug)] 93#[derive(Debug)]
94pub struct UnconfiguredCode { 94pub struct InactiveCode {
95 pub file: HirFileId, 95 pub file: HirFileId,
96 pub node: SyntaxNodePtr, 96 pub node: SyntaxNodePtr,
97} 97}
98 98
99impl Diagnostic for UnconfiguredCode { 99impl Diagnostic for InactiveCode {
100 fn code(&self) -> DiagnosticCode { 100 fn code(&self) -> DiagnosticCode {
101 DiagnosticCode("unconfigured-code") 101 DiagnosticCode("inactive-code")
102 } 102 }
103 fn message(&self) -> String { 103 fn message(&self) -> String {
104 // FIXME: say *why* it is configured out 104 // FIXME: say *why* it is configured out
diff --git a/crates/hir_def/src/nameres.rs b/crates/hir_def/src/nameres.rs
index 8bb3a659f..01a28aeeb 100644
--- a/crates/hir_def/src/nameres.rs
+++ b/crates/hir_def/src/nameres.rs
@@ -396,7 +396,7 @@ mod diagnostics {
396 } 396 }
397 397
398 DiagnosticKind::UnconfiguredCode { ast } => { 398 DiagnosticKind::UnconfiguredCode { ast } => {
399 sink.push(UnconfiguredCode { file: ast.file_id, node: ast.value.clone() }); 399 sink.push(InactiveCode { file: ast.file_id, node: ast.value.clone() });
400 } 400 }
401 } 401 }
402 } 402 }