4 pub(in E) struct S; //~ ERROR expected module, found enum `E`
5 pub(in Tr) struct Z; //~ ERROR expected module, found trait `Tr`
6 pub(in std::vec) struct F; //~ ERROR visibilities can only be restricted to ancestor modules
7 pub(in nonexistent) struct G; //~ ERROR failed to resolve
8 pub(in too_soon) struct H; //~ ERROR failed to resolve
10 // Visibilities are resolved eagerly without waiting for modules becoming fully populated.
11 // Visibilities can only use ancestor modules legally which are always available in time,
12 // so the worst thing that can happen due to eager resolution is a suboptimal error message.