We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
pub
1 parent 573c1d5 commit 87403b8Copy full SHA for 87403b8
src/librustc_resolve/resolve_imports.rs
@@ -78,6 +78,9 @@ impl<'a> ImportDirective<'a> {
78
};
79
if let GlobImport = self.subclass {
80
modifiers = modifiers | DefModifiers::GLOB_IMPORTED;
81
+ } else if self.is_public && binding.is_extern_crate() {
82
+ // `pub` single imports of private extern crates are public (see #31362).
83
+ modifiers = modifiers | DefModifiers::PUBLIC;
84
}
85
86
NameBinding {
0 commit comments