mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 12:29:21 +00:00
Rename some things and turn macro to macro def into a query
This commit is contained in:
parent
071fe4e4e9
commit
51a9e7831a
21 changed files with 165 additions and 163 deletions
|
@ -13,7 +13,6 @@ use either::Either;
|
|||
use hir_def::{
|
||||
hir::Expr,
|
||||
lower::LowerCtx,
|
||||
macro_id_to_def_id,
|
||||
nameres::MacroSubNs,
|
||||
resolver::{self, HasResolver, Resolver, TypeNs},
|
||||
type_ref::Mutability,
|
||||
|
@ -343,7 +342,7 @@ impl<'db> SemanticsImpl<'db> {
|
|||
let macro_call_id = macro_call.as_call_id(self.db.upcast(), krate, |path| {
|
||||
resolver
|
||||
.resolve_path_as_macro(self.db.upcast(), &path, Some(MacroSubNs::Bang))
|
||||
.map(|(it, _)| macro_id_to_def_id(self.db.upcast(), it))
|
||||
.map(|(it, _)| self.db.macro_def(it))
|
||||
})?;
|
||||
hir_expand::db::expand_speculative(
|
||||
self.db.upcast(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue