]> git.proxmox.com Git - rustc.git/blob - src/test/ui/imports/issue-62767.rs
0e0f915ea53c20069e7fcbfea0b1d55922a15794
[rustc.git] / src / test / ui / imports / issue-62767.rs
1 // Minimized case from #62767.
2 mod m {
3 pub enum Same {
4 Same,
5 }
6 }
7
8 use m::*;
9
10 // The variant `Same` introduced by this import is also considered when resolving the prefix
11 // `Same::` during import validation to avoid effects similar to time travel (#74556).
12 use Same::Same; //~ ERROR unresolved import `Same`
13
14 // Case from #74556.
15 mod foo {
16 pub mod bar {
17 pub mod bar {
18 pub fn foobar() {}
19 }
20 }
21 }
22
23 use foo::*;
24 use bar::bar; //~ ERROR unresolved import `bar::bar`
25 //~| ERROR inconsistent resolution for an import
26 use bar::foobar;
27
28 fn main() {}