1 error[E0412]: cannot find type `Apple` in this scope
2 --> $DIR/issue-35675.rs:17:29
4 LL | fn should_return_fruit() -> Apple {
5 | ^^^^^ not found in this scope
6 help: there is an enum variant `Fruit::Apple`; try using the variant's enum
8 LL | fn should_return_fruit() -> Fruit {
11 error[E0425]: cannot find function `Apple` in this scope
12 --> $DIR/issue-35675.rs:19:5
15 | ^^^^^ not found in this scope
16 help: possible candidate is found in another module, you can import it into scope
18 LL | use Fruit::Apple;
21 error[E0573]: expected type, found variant `Fruit::Apple`
22 --> $DIR/issue-35675.rs:23:33
24 LL | fn should_return_fruit_too() -> Fruit::Apple {
28 | help: try using the variant's enum: `Fruit`
30 error[E0425]: cannot find function `Apple` in this scope
31 --> $DIR/issue-35675.rs:25:5
34 | ^^^^^ not found in this scope
35 help: possible candidate is found in another module, you can import it into scope
37 LL | use Fruit::Apple;
40 error[E0573]: expected type, found variant `Ok`
41 --> $DIR/issue-35675.rs:29:13
45 help: try using the variant's enum
47 LL | fn foo() -> std::prelude::v1 {
49 LL | fn foo() -> std::result::Result {
52 error[E0412]: cannot find type `Variant3` in this scope
53 --> $DIR/issue-35675.rs:34:13
55 LL | fn bar() -> Variant3 {
56 | ^^^^^^^^ not found in this scope
57 help: there is an enum variant `x::Enum::Variant3`; try using the variant's enum
59 LL | fn bar() -> x::Enum {
62 error[E0573]: expected type, found variant `Some`
63 --> $DIR/issue-35675.rs:38:13
65 LL | fn qux() -> Some {
67 help: try using the variant's enum
69 LL | fn qux() -> std::prelude::v1::Option {
70 | ^^^^^^^^^^^^^^^^^^^^^^^^
71 LL | fn qux() -> std::prelude::v1 {
74 error: aborting due to 7 previous errors
76 Some errors occurred: E0412, E0425, E0573.
77 For more information about an error, try `rustc --explain E0412`.