@@ -16,15 +16,11 @@ LL | m::Z::Unit;
16
16
error[E0423]: expected value, found enum `Z`
17
17
--> $DIR/privacy-enum-ctor.rs:25:9
18
18
|
19
- LL | / fn f() {
20
- LL | | n::Z;
21
- LL | |
22
- LL | | Z;
23
- | | ^
24
- ... |
25
- LL | | // This is ok, it is equivalent to not having braces
26
- LL | | }
27
- | |_____- similarly named function `f` defined here
19
+ LL | fn f() {
20
+ | ------ similarly named function `f` defined here
21
+ ...
22
+ LL | Z;
23
+ | ^
28
24
|
29
25
help: a function with a similar name exists
30
26
|
@@ -53,17 +49,11 @@ LL | let _: Z = Z::Struct;
53
49
error[E0423]: expected value, found enum `m::E`
54
50
--> $DIR/privacy-enum-ctor.rs:41:16
55
51
|
56
- LL | / fn f() {
57
- LL | | n::Z;
58
- LL | |
59
- LL | | Z;
60
- ... |
61
- LL | | // This is ok, it is equivalent to not having braces
62
- LL | | }
63
- | |_____- similarly named function `f` defined here
52
+ LL | fn f() {
53
+ | ------ similarly named function `f` defined here
64
54
...
65
- LL | let _: E = m::E;
66
- | ^^^^
55
+ LL | let _: E = m::E;
56
+ | ^^^^
67
57
|
68
58
help: a function with a similar name exists
69
59
|
@@ -130,17 +120,11 @@ LL | let _: E = E::Struct;
130
120
error[E0412]: cannot find type `Z` in this scope
131
121
--> $DIR/privacy-enum-ctor.rs:57:12
132
122
|
133
- LL | / pub enum E {
134
- LL | | Fn(u8),
135
- LL | | Struct {
136
- LL | | s: u8,
137
- LL | | },
138
- LL | | Unit,
139
- LL | | }
140
- | |_____- similarly named enum `E` defined here
123
+ LL | pub enum E {
124
+ | ---------- similarly named enum `E` defined here
141
125
...
142
- LL | let _: Z = m::n::Z;
143
- | ^
126
+ LL | let _: Z = m::n::Z;
127
+ | ^
144
128
|
145
129
help: an enum with a similar name exists
146
130
|
@@ -169,17 +153,11 @@ LL | let _: Z = m::Z::Unit;
169
153
error[E0412]: cannot find type `Z` in this scope
170
154
--> $DIR/privacy-enum-ctor.rs:61:12
171
155
|
172
- LL | / pub enum E {
173
- LL | | Fn(u8),
174
- LL | | Struct {
175
- LL | | s: u8,
176
- LL | | },
177
- LL | | Unit,
178
- LL | | }
179
- | |_____- similarly named enum `E` defined here
156
+ LL | pub enum E {
157
+ | ---------- similarly named enum `E` defined here
180
158
...
181
- LL | let _: Z = m::n::Z::Fn;
182
- | ^
159
+ LL | let _: Z = m::n::Z::Fn;
160
+ | ^
183
161
|
184
162
help: an enum with a similar name exists
185
163
|
@@ -193,17 +171,11 @@ LL | use m::n::Z;
193
171
error[E0412]: cannot find type `Z` in this scope
194
172
--> $DIR/privacy-enum-ctor.rs:64:12
195
173
|
196
- LL | / pub enum E {
197
- LL | | Fn(u8),
198
- LL | | Struct {
199
- LL | | s: u8,
200
- LL | | },
201
- LL | | Unit,
202
- LL | | }
203
- | |_____- similarly named enum `E` defined here
174
+ LL | pub enum E {
175
+ | ---------- similarly named enum `E` defined here
204
176
...
205
- LL | let _: Z = m::n::Z::Struct;
206
- | ^
177
+ LL | let _: Z = m::n::Z::Struct;
178
+ | ^
207
179
|
208
180
help: an enum with a similar name exists
209
181
|
@@ -228,17 +200,11 @@ LL | let _: Z = m::n::Z::Struct;
228
200
error[E0412]: cannot find type `Z` in this scope
229
201
--> $DIR/privacy-enum-ctor.rs:68:12
230
202
|
231
- LL | / pub enum E {
232
- LL | | Fn(u8),
233
- LL | | Struct {
234
- LL | | s: u8,
235
- LL | | },
236
- LL | | Unit,
237
- LL | | }
238
- | |_____- similarly named enum `E` defined here
203
+ LL | pub enum E {
204
+ | ---------- similarly named enum `E` defined here
239
205
...
240
- LL | let _: Z = m::n::Z::Unit {};
241
- | ^
206
+ LL | let _: Z = m::n::Z::Unit {};
207
+ | ^
242
208
|
243
209
help: an enum with a similar name exists
244
210
|
0 commit comments