Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-def/src/expander.rs')
-rw-r--r--crates/hir-def/src/expander.rs9
1 files changed, 3 insertions, 6 deletions
diff --git a/crates/hir-def/src/expander.rs b/crates/hir-def/src/expander.rs
index 57bd54ed17..6d8b4445f7 100644
--- a/crates/hir-def/src/expander.rs
+++ b/crates/hir-def/src/expander.rs
@@ -69,12 +69,9 @@ impl Expander {
let result = self.within_limit(db, |this| {
let macro_call = this.in_file(&macro_call);
- match macro_call.as_call_id(
- db.upcast(),
- this.module,
- |path| resolver(path).map(|it| db.macro_def(it)),
- |module| this.module.def_map(db).path_for_module(db, module),
- ) {
+ match macro_call.as_call_id_with_errors(db.upcast(), this.module.krate(), |path| {
+ resolver(path).map(|it| db.macro_def(it))
+ }) {
Ok(call_id) => call_id,
Err(resolve_err) => {
unresolved_macro_err = Some(resolve_err);