1 error[E0423]: expected value, found enum `n::Z`
2 --> $DIR/privacy-enum-ctor.rs:23:9
7 = note: did you mean to use one of the following variants?
12 error[E0423]: expected value, found enum `Z`
13 --> $DIR/privacy-enum-ctor.rs:25:9
16 | ^ help: a function with a similar name exists: `f`
18 = note: did you mean to use one of the following variants?
23 error[E0423]: expected value, found struct variant `Z::Struct`
24 --> $DIR/privacy-enum-ctor.rs:29:20
26 LL | let _: Z = Z::Struct;
27 | ^^^^^^^^^ did you mean `Z::Struct { /* fields */ }`?
29 error[E0423]: expected value, found enum `m::E`
30 --> $DIR/privacy-enum-ctor.rs:41:16
35 = note: did you mean to use one of the following variants?
39 help: a function with a similar name exists
43 help: possible better candidates are found in other modules, you can import them into scope
45 LL | use std::f32::consts::E;
47 LL | use std::f64::consts::E;
50 error[E0423]: expected value, found struct variant `m::E::Struct`
51 --> $DIR/privacy-enum-ctor.rs:45:16
53 LL | let _: E = m::E::Struct;
54 | ^^^^^^^^^^^^ did you mean `m::E::Struct { /* fields */ }`?
56 error[E0423]: expected value, found enum `E`
57 --> $DIR/privacy-enum-ctor.rs:49:16
62 = note: did you mean to use one of the following variants?
66 help: possible better candidates are found in other modules, you can import them into scope
68 LL | use std::f32::consts::E;
70 LL | use std::f64::consts::E;
73 error[E0423]: expected value, found struct variant `E::Struct`
74 --> $DIR/privacy-enum-ctor.rs:53:16
76 LL | let _: E = E::Struct;
77 | ^^^^^^^^^ did you mean `E::Struct { /* fields */ }`?
79 error[E0412]: cannot find type `Z` in this scope
80 --> $DIR/privacy-enum-ctor.rs:57:12
82 LL | let _: Z = m::n::Z;
84 help: an enum with a similar name exists
86 LL | let _: E = m::n::Z;
88 help: possible candidate is found in another module, you can import it into scope
93 error[E0423]: expected value, found enum `m::n::Z`
94 --> $DIR/privacy-enum-ctor.rs:57:16
96 LL | let _: Z = m::n::Z;
99 = note: did you mean to use one of the following variants?
104 error[E0412]: cannot find type `Z` in this scope
105 --> $DIR/privacy-enum-ctor.rs:61:12
107 LL | let _: Z = m::n::Z::Fn;
109 help: an enum with a similar name exists
111 LL | let _: E = m::n::Z::Fn;
113 help: possible candidate is found in another module, you can import it into scope
118 error[E0412]: cannot find type `Z` in this scope
119 --> $DIR/privacy-enum-ctor.rs:64:12
121 LL | let _: Z = m::n::Z::Struct;
123 help: an enum with a similar name exists
125 LL | let _: E = m::n::Z::Struct;
127 help: possible candidate is found in another module, you can import it into scope
132 error[E0423]: expected value, found struct variant `m::n::Z::Struct`
133 --> $DIR/privacy-enum-ctor.rs:64:16
135 LL | let _: Z = m::n::Z::Struct;
136 | ^^^^^^^^^^^^^^^ did you mean `m::n::Z::Struct { /* fields */ }`?
138 error[E0412]: cannot find type `Z` in this scope
139 --> $DIR/privacy-enum-ctor.rs:68:12
141 LL | let _: Z = m::n::Z::Unit {};
143 help: an enum with a similar name exists
145 LL | let _: E = m::n::Z::Unit {};
147 help: possible candidate is found in another module, you can import it into scope
152 error[E0603]: enum `Z` is private
153 --> $DIR/privacy-enum-ctor.rs:57:22
155 LL | let _: Z = m::n::Z;
158 error[E0603]: enum `Z` is private
159 --> $DIR/privacy-enum-ctor.rs:61:22
161 LL | let _: Z = m::n::Z::Fn;
164 error[E0603]: enum `Z` is private
165 --> $DIR/privacy-enum-ctor.rs:64:22
167 LL | let _: Z = m::n::Z::Struct;
170 error[E0603]: enum `Z` is private
171 --> $DIR/privacy-enum-ctor.rs:68:22
173 LL | let _: Z = m::n::Z::Unit {};
176 error[E0308]: mismatched types
177 --> $DIR/privacy-enum-ctor.rs:27:20
179 LL | let _: Z = Z::Fn;
180 | ^^^^^ expected enum `m::n::Z`, found fn item
182 = note: expected type `m::n::Z`
183 found type `fn(u8) -> m::n::Z {m::n::Z::Fn}`
185 error[E0618]: expected function, found enum variant `Z::Unit`
186 --> $DIR/privacy-enum-ctor.rs:31:17
189 | ---- `Z::Unit` defined here
191 LL | let _ = Z::Unit();
194 | call expression requires function
195 help: `Z::Unit` is a unit variant, you need to write it without the parenthesis
197 LL | let _ = Z::Unit;
200 error[E0308]: mismatched types
201 --> $DIR/privacy-enum-ctor.rs:43:16
203 LL | let _: E = m::E::Fn;
204 | ^^^^^^^^ expected enum `m::E`, found fn item
206 = note: expected type `m::E`
207 found type `fn(u8) -> m::E {m::E::Fn}`
209 error[E0618]: expected function, found enum variant `m::E::Unit`
210 --> $DIR/privacy-enum-ctor.rs:47:16
213 | ---- `m::E::Unit` defined here
215 LL | let _: E = m::E::Unit();
218 | call expression requires function
219 help: `m::E::Unit` is a unit variant, you need to write it without the parenthesis
221 LL | let _: E = m::E::Unit;
224 error[E0308]: mismatched types
225 --> $DIR/privacy-enum-ctor.rs:51:16
227 LL | let _: E = E::Fn;
228 | ^^^^^ expected enum `m::E`, found fn item
230 = note: expected type `m::E`
231 found type `fn(u8) -> m::E {m::E::Fn}`
233 error[E0618]: expected function, found enum variant `E::Unit`
234 --> $DIR/privacy-enum-ctor.rs:55:16
237 | ---- `E::Unit` defined here
239 LL | let _: E = E::Unit();
242 | call expression requires function
243 help: `E::Unit` is a unit variant, you need to write it without the parenthesis
245 LL | let _: E = E::Unit;
248 error: aborting due to 23 previous errors
250 Some errors occurred: E0308, E0412, E0423, E0603, E0618.
251 For more information about an error, try `rustc --explain E0308`.