Auto merge of #17462 - Veykril:sema-attr-macro-res, r=Veykril

fix: Fix IDE features breaking in some attr macros

Fixes https://github.com/rust-lang/rust-analyzer/issues/17453, Fixes https://github.com/rust-lang/rust-analyzer/issues/17458
This commit is contained in:
bors 2024-06-20 09:11:44 +00:00
commit e08f7953f4
3 changed files with 6 additions and 6 deletions

View file

@ -710,8 +710,8 @@ impl ExpansionInfo {
self.expanded.clone()
}
pub fn call_node(&self) -> InFile<Option<SyntaxNode>> {
self.arg.with_value(self.arg.value.as_ref().and_then(SyntaxNode::parent))
pub fn arg(&self) -> InFile<Option<&SyntaxNode>> {
self.arg.as_ref().map(|it| it.as_ref())
}
pub fn call_file(&self) -> HirFileId {