Skip to content

Commit 10c9efc

Browse files
committed
Expand doc on dealing with "proc macro not expanded"
Added the error message to the doc for the UnresolvedProcMacro diagnostic, explaining that either enabling the procMacro setting or disabling this diagnostic should make the warnings go away.
1 parent 6168a6f commit 10c9efc

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

crates/hir_def/src/diagnostics.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,10 @@ impl Diagnostic for InactiveCode {
133133
// This diagnostic is shown when a procedural macro can not be found. This usually means that
134134
// procedural macro support is simply disabled (and hence is only a weak hint instead of an error),
135135
// but can also indicate project setup problems.
136+
//
137+
// If you are seeing a lot of "proc macro not expanded" warnings, you can add this option to the
138+
// `rust-analyzer.diagnostics.disabled` list to prevent them from showing. Alternatively you can
139+
// enable support for procedural macros (see `rust-analyzer.procMacro.enable`).
136140
#[derive(Debug, Clone, Eq, PartialEq)]
137141
pub struct UnresolvedProcMacro {
138142
pub file: HirFileId,

0 commit comments

Comments
 (0)