summary refs log tree commit diff
path: root/src/test/ui/resolve/privacy-struct-ctor.stderr
blob: f7e5c602644cfa0a8bb5c431309fba9d2b55ffe7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
error[E0423]: expected value, found struct `Z`
  --> $DIR/privacy-struct-ctor.rs:26:9
   |
26 |         Z;
   |         ^
   |         |
   |         did you mean `S`?
   |         constructor is not visible here due to private fields
   |         did you mean `Z { /* fields */ }`?
   |
help: possible better candidate is found in another module, you can import it into scope
   |
22 |     use m::n::Z;
   |

error[E0423]: expected value, found struct `S`
  --> $DIR/privacy-struct-ctor.rs:36:5
   |
36 |     S;
   |     ^
   |     |
   |     constructor is not visible here due to private fields
   |     did you mean `S { /* fields */ }`?
   |
help: possible better candidate is found in another module, you can import it into scope
   |
32 | use m::S;
   |

error[E0423]: expected value, found struct `xcrate::S`
  --> $DIR/privacy-struct-ctor.rs:42:5
   |
42 |     xcrate::S;
   |     ^^^^^^^^^
   |     |
   |     constructor is not visible here due to private fields
   |     did you mean `xcrate::S { /* fields */ }`?
   |
help: possible better candidate is found in another module, you can import it into scope
   |
32 | use m::S;
   |

error[E0603]: tuple struct `Z` is private
  --> $DIR/privacy-struct-ctor.rs:25:9
   |
25 |         n::Z; //~ ERROR tuple struct `Z` is private
   |         ^^^^

error[E0603]: tuple struct `S` is private
  --> $DIR/privacy-struct-ctor.rs:35:5
   |
35 |     m::S; //~ ERROR tuple struct `S` is private
   |     ^^^^

error[E0603]: tuple struct `Z` is private
  --> $DIR/privacy-struct-ctor.rs:39:5
   |
39 |     m::n::Z; //~ ERROR tuple struct `Z` is private
   |     ^^^^^^^

error[E0603]: tuple struct `S` is private
  --> $DIR/privacy-struct-ctor.rs:41:5
   |
41 |     xcrate::m::S; //~ ERROR tuple struct `S` is private
   |     ^^^^^^^^^^^^

error[E0603]: tuple struct `Z` is private
  --> $DIR/privacy-struct-ctor.rs:45:5
   |
45 |     xcrate::m::n::Z; //~ ERROR tuple struct `Z` is private
   |     ^^^^^^^^^^^^^^^

error: aborting due to 8 previous errors