1 error[E0412]: cannot find type `Bar` in this scope
2 --> $DIR/issue-4366-2.rs:15:21
4 LL | fn sub() -> Bar { 1 }
5 | ^^^ not found in this scope
6 help: possible candidate is found in another module, you can import it into scope
11 error[E0423]: expected function, found module `foo`
12 --> $DIR/issue-4366-2.rs:25:5
14 LL | foo(); //~ ERROR expected function, found module `foo`
16 help: possible better candidates are found in other modules, you can import them into scope
23 error: aborting due to 2 previous errors
25 Some errors occurred: E0412, E0423.
26 For more information about an error, try `rustc --explain E0412`.