mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-26 20:09:19 +00:00
Improve macro descension API
This commit is contained in:
parent
986577faaa
commit
5b8e386bae
21 changed files with 179 additions and 139 deletions
|
@ -1,6 +1,6 @@
|
|||
//! Entry point for call-hierarchy
|
||||
|
||||
use hir::Semantics;
|
||||
use hir::{DescendPreference, Semantics};
|
||||
use ide_db::{
|
||||
defs::{Definition, NameClass, NameRefClass},
|
||||
helpers::pick_best_token,
|
||||
|
@ -87,7 +87,7 @@ pub(crate) fn outgoing_calls(
|
|||
})?;
|
||||
let mut calls = CallLocations::default();
|
||||
|
||||
sema.descend_into_macros(token, offset)
|
||||
sema.descend_into_macros(DescendPreference::None, token, offset)
|
||||
.into_iter()
|
||||
.filter_map(|it| it.parent_ancestors().nth(1).and_then(ast::Item::cast))
|
||||
.filter_map(|item| match item {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue