mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-30 22:01:37 +00:00
Auto merge of #17405 - Veykril:modpath-clone, r=Veykril
internal: Don't unnecessarily clone ModPaths in early name res
This commit is contained in:
commit
22648b2655
12 changed files with 29 additions and 30 deletions
|
@ -416,9 +416,9 @@ impl<'a> TyLoweringContext<'a> {
|
|||
};
|
||||
let ty = {
|
||||
let macro_call = macro_call.to_node(self.db.upcast());
|
||||
let resolver = |path| {
|
||||
let resolver = |path: &_| {
|
||||
self.resolver
|
||||
.resolve_path_as_macro(self.db.upcast(), &path, Some(MacroSubNs::Bang))
|
||||
.resolve_path_as_macro(self.db.upcast(), path, Some(MacroSubNs::Bang))
|
||||
.map(|(it, _)| it)
|
||||
};
|
||||
match expander.enter_expand::<ast::Type>(self.db.upcast(), macro_call, resolver)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue