We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 51f25b3 commit 8d9ba29Copy full SHA for 8d9ba29
src/librustc_resolve/macros.rs
@@ -205,7 +205,10 @@ impl<'a> base::Resolver for Resolver<'a> {
205
}
206
207
let ext = match self.resolve_path(&path, path_scope, Some(MacroNS), None) {
208
- PathResult::NonModule(path_res) => Ok(self.get_macro(path_res.base_def)),
+ PathResult::NonModule(path_res) => match path_res.base_def {
209
+ Def::Err => Err(Determinacy::Determined),
210
+ def @ _ => Ok(self.get_macro(def)),
211
+ },
212
PathResult::Module(..) => unreachable!(),
213
PathResult::Indeterminate if !force => return Err(Determinacy::Undetermined),
214
_ => Err(Determinacy::Determined),
0 commit comments