diff options
author | Jonas Schievink <[email protected]> | 2021-06-11 17:12:51 +0100 |
---|---|---|
committer | Jonas Schievink <[email protected]> | 2021-06-11 17:34:30 +0100 |
commit | 1d6eef1350ee0793fcd2a0eb191cdb127b76a49d (patch) | |
tree | 6f3f37d7ac665a7b6b6325da0d3b411741cd7069 /crates/ide_db/src | |
parent | 80b3b740184a6a64ee0ff8767ab6f5b786dc0dd7 (diff) |
Update ungrammar
Diffstat (limited to 'crates/ide_db/src')
-rw-r--r-- | crates/ide_db/src/defs.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ide_db/src/defs.rs b/crates/ide_db/src/defs.rs index 1b69d72f9..a54f2c323 100644 --- a/crates/ide_db/src/defs.rs +++ b/crates/ide_db/src/defs.rs | |||
@@ -369,7 +369,7 @@ impl NameRefClass { | |||
369 | } | 369 | } |
370 | 370 | ||
371 | if let Some(resolved) = sema.resolve_path(&path) { | 371 | if let Some(resolved) = sema.resolve_path(&path) { |
372 | if path.syntax().parent().and_then(ast::Attr::cast).is_some() { | 372 | if path.syntax().ancestors().find_map(ast::Attr::cast).is_some() { |
373 | if let PathResolution::Def(ModuleDef::Function(func)) = resolved { | 373 | if let PathResolution::Def(ModuleDef::Function(func)) = resolved { |
374 | if func.attrs(sema.db).by_key("proc_macro_attribute").exists() { | 374 | if func.attrs(sema.db).by_key("proc_macro_attribute").exists() { |
375 | return Some(NameRefClass::Definition(resolved.into())); | 375 | return Some(NameRefClass::Definition(resolved.into())); |