Skip to content

Commit d1f28f6

Browse files
committed
Add regression test for rust-lang#22146
1 parent 7979dd6 commit d1f28f6

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/test/compile-fail/extern-crate-visibility.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,5 +30,14 @@ fn f() {
3030
mod core {} // Check that private crates are not glob imported
3131
}
3232

33+
mod bar {
34+
pub extern crate core;
35+
}
36+
37+
mod baz {
38+
pub use bar::*;
39+
use self::core::cell; // Check that public extern crates are glob imported
40+
}
41+
3342
#[rustc_error]
3443
fn main() {} //~ ERROR compilation successful

0 commit comments

Comments
 (0)