commit
39eaf7864c
1 changed files with 7 additions and 7 deletions
|
@ -18,7 +18,7 @@ use crate::{
|
||||||
ConstId, HasModule, ImplId, LocalModuleId, MacroId, ModuleDefId, ModuleId, TraitId,
|
ConstId, HasModule, ImplId, LocalModuleId, MacroId, ModuleDefId, ModuleId, TraitId,
|
||||||
};
|
};
|
||||||
|
|
||||||
#[derive(Copy, Clone)]
|
#[derive(Copy, Clone, Debug)]
|
||||||
pub(crate) enum ImportType {
|
pub(crate) enum ImportType {
|
||||||
Glob,
|
Glob,
|
||||||
Named,
|
Named,
|
||||||
|
@ -302,13 +302,13 @@ impl ItemScope {
|
||||||
$changed = true;
|
$changed = true;
|
||||||
}
|
}
|
||||||
Entry::Occupied(mut entry)
|
Entry::Occupied(mut entry)
|
||||||
if $glob_imports.$field.contains(&$lookup)
|
if matches!($def_import_type, ImportType::Named) =>
|
||||||
&& matches!($def_import_type, ImportType::Named) =>
|
|
||||||
{
|
{
|
||||||
cov_mark::hit!(import_shadowed);
|
if $glob_imports.$field.remove(&$lookup) {
|
||||||
$glob_imports.$field.remove(&$lookup);
|
cov_mark::hit!(import_shadowed);
|
||||||
entry.insert(fld);
|
entry.insert(fld);
|
||||||
$changed = true;
|
$changed = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue