]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-21546.stderr
Consider privacy more carefully when suggesting accessing fields
[rust.git] / src / test / ui / issues / issue-21546.stderr
1 error[E0428]: the name `Foo` is defined multiple times
2   --> $DIR/issue-21546.rs:7:1
3    |
4 LL | mod Foo { }
5    | ------- previous definition of the module `Foo` here
6 ...
7 LL | struct Foo;
8    | ^^^^^^^^^^^ `Foo` redefined here
9    |
10    = note: `Foo` must be defined only once in the type namespace of this module
11
12 error[E0428]: the name `Bar` is defined multiple times
13   --> $DIR/issue-21546.rs:14:1
14    |
15 LL | mod Bar { }
16    | ------- previous definition of the module `Bar` here
17 ...
18 LL | struct Bar(i32);
19    | ^^^^^^^^^^^^^^^^ `Bar` redefined here
20    |
21    = note: `Bar` must be defined only once in the type namespace of this module
22
23 error[E0428]: the name `Baz` is defined multiple times
24   --> $DIR/issue-21546.rs:22:1
25    |
26 LL | struct Baz(i32);
27    | ---------------- previous definition of the type `Baz` here
28 ...
29 LL | mod Baz { }
30    | ^^^^^^^ `Baz` redefined here
31    |
32    = note: `Baz` must be defined only once in the type namespace of this module
33
34 error[E0428]: the name `Qux` is defined multiple times
35   --> $DIR/issue-21546.rs:30:1
36    |
37 LL | struct Qux { x: bool }
38    | ---------- previous definition of the type `Qux` here
39 ...
40 LL | mod Qux { }
41    | ^^^^^^^ `Qux` redefined here
42    |
43    = note: `Qux` must be defined only once in the type namespace of this module
44
45 error[E0428]: the name `Quux` is defined multiple times
46   --> $DIR/issue-21546.rs:38:1
47    |
48 LL | struct Quux;
49    | ------------ previous definition of the type `Quux` here
50 ...
51 LL | mod Quux { }
52    | ^^^^^^^^ `Quux` redefined here
53    |
54    = note: `Quux` must be defined only once in the type namespace of this module
55
56 error[E0428]: the name `Corge` is defined multiple times
57   --> $DIR/issue-21546.rs:46:1
58    |
59 LL | enum Corge { A, B }
60    | ---------- previous definition of the type `Corge` here
61 ...
62 LL | mod Corge { }
63    | ^^^^^^^^^ `Corge` redefined here
64    |
65    = note: `Corge` must be defined only once in the type namespace of this module
66
67 error: aborting due to 6 previous errors
68
69 For more information about this error, try `rustc --explain E0428`.