Skip to content

Commit 765722f

Browse files
committed
add glob import check in ModuleScope::Glob
1 parent f9a6e87 commit 765722f

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

compiler/rustc_resolve/src/ident.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -931,6 +931,12 @@ impl<'ra, 'tcx> Resolver<'ra, 'tcx> {
931931
.into_iter()
932932
.find_map(|binding| if binding == ignore_binding { None } else { binding });
933933

934+
if let Some(binding) = binding {
935+
if !binding.is_glob_import() {
936+
return None;
937+
}
938+
}
939+
934940
if let Some(finalize) = finalize {
935941
return Some(this.finalize_module_binding(
936942
ident,

0 commit comments

Comments
 (0)