We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1e9a323 commit 4d5e80cCopy full SHA for 4d5e80c
crates/ra_hir_expand/src/db.rs
@@ -172,9 +172,20 @@ pub(crate) fn parse_macro(
172
// Note:
173
// The final goal we would like to make all parse_macro success,
174
// such that the following log will not call anyway.
175
- let loc: MacroCallLoc = db.lookup_intern_macro(macro_call_id);
176
- let node = loc.kind.node(db);
177
- log::warn!("fail on macro_parse: (reason: {} macro_call: {:#})", err, node.value);
+ match macro_call_id {
+ MacroCallId::LazyMacro(id) => {
+ let loc: MacroCallLoc = db.lookup_intern_macro(id);
178
+ let node = loc.kind.node(db);
179
+ log::warn!(
180
+ "fail on macro_parse: (reason: {} macro_call: {:#})",
181
+ err,
182
+ node.value
183
+ );
184
+ }
185
+ _ => {
186
+ log::warn!("fail on macro_parse: (reason: {})", err);
187
188
189
})
190
.ok()?;
191
0 commit comments