]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/explicit_auto_deref.stderr
Merge commit 'fdb84cbfd25908df5683f8f62388f663d9260e39' into clippyup
[rust.git] / src / tools / clippy / tests / ui / explicit_auto_deref.stderr
1 error: deref which would be done by auto-deref
2   --> $DIR/explicit_auto_deref.rs:69:20
3    |
4 LL |     let _: &str = &*s;
5    |                    ^^ help: try this: `s`
6    |
7    = note: `-D clippy::explicit-auto-deref` implied by `-D warnings`
8
9 error: deref which would be done by auto-deref
10   --> $DIR/explicit_auto_deref.rs:73:12
11    |
12 LL |     f_str(&*s);
13    |            ^^ help: try this: `s`
14
15 error: deref which would be done by auto-deref
16   --> $DIR/explicit_auto_deref.rs:77:14
17    |
18 LL |     f_str_t(&*s, &*s); // Don't lint second param.
19    |              ^^ help: try this: `s`
20
21 error: deref which would be done by auto-deref
22   --> $DIR/explicit_auto_deref.rs:80:25
23    |
24 LL |     let _: &Box<i32> = &**b;
25    |                         ^^^ help: try this: `b`
26
27 error: deref which would be done by auto-deref
28   --> $DIR/explicit_auto_deref.rs:86:8
29    |
30 LL |     c(&*s);
31    |        ^^ help: try this: `s`
32
33 error: deref which would be done by auto-deref
34   --> $DIR/explicit_auto_deref.rs:92:9
35    |
36 LL |         &**x
37    |         ^^^^ help: try this: `x`
38
39 error: deref which would be done by auto-deref
40   --> $DIR/explicit_auto_deref.rs:96:11
41    |
42 LL |         { &**x }
43    |           ^^^^ help: try this: `x`
44
45 error: deref which would be done by auto-deref
46   --> $DIR/explicit_auto_deref.rs:100:9
47    |
48 LL |         &**{ x }
49    |         ^^^^^^^^ help: try this: `{ x }`
50
51 error: deref which would be done by auto-deref
52   --> $DIR/explicit_auto_deref.rs:104:9
53    |
54 LL |         &***x
55    |         ^^^^^ help: try this: `x`
56
57 error: deref which would be done by auto-deref
58   --> $DIR/explicit_auto_deref.rs:121:13
59    |
60 LL |         f1(&*x);
61    |             ^^ help: try this: `x`
62
63 error: deref which would be done by auto-deref
64   --> $DIR/explicit_auto_deref.rs:122:13
65    |
66 LL |         f2(&*x);
67    |             ^^ help: try this: `x`
68
69 error: deref which would be done by auto-deref
70   --> $DIR/explicit_auto_deref.rs:123:13
71    |
72 LL |         f3(&*x);
73    |             ^^ help: try this: `x`
74
75 error: deref which would be done by auto-deref
76   --> $DIR/explicit_auto_deref.rs:124:28
77    |
78 LL |         f4.callable_str()(&*x);
79    |                            ^^ help: try this: `x`
80
81 error: deref which would be done by auto-deref
82   --> $DIR/explicit_auto_deref.rs:125:13
83    |
84 LL |         f5(&*x);
85    |             ^^ help: try this: `x`
86
87 error: deref which would be done by auto-deref
88   --> $DIR/explicit_auto_deref.rs:126:13
89    |
90 LL |         f6(&*x);
91    |             ^^ help: try this: `x`
92
93 error: deref which would be done by auto-deref
94   --> $DIR/explicit_auto_deref.rs:127:28
95    |
96 LL |         f7.callable_str()(&*x);
97    |                            ^^ help: try this: `x`
98
99 error: deref which would be done by auto-deref
100   --> $DIR/explicit_auto_deref.rs:128:26
101    |
102 LL |         f8.callable_t()(&*x);
103    |                          ^^ help: try this: `x`
104
105 error: deref which would be done by auto-deref
106   --> $DIR/explicit_auto_deref.rs:129:13
107    |
108 LL |         f9(&*x);
109    |             ^^ help: try this: `x`
110
111 error: deref which would be done by auto-deref
112   --> $DIR/explicit_auto_deref.rs:130:14
113    |
114 LL |         f10(&*x);
115    |              ^^ help: try this: `x`
116
117 error: deref which would be done by auto-deref
118   --> $DIR/explicit_auto_deref.rs:131:27
119    |
120 LL |         f11.callable_t()(&*x);
121    |                           ^^ help: try this: `x`
122
123 error: deref which would be done by auto-deref
124   --> $DIR/explicit_auto_deref.rs:135:17
125    |
126 LL |     let _ = S1(&*s);
127    |                 ^^ help: try this: `s`
128
129 error: deref which would be done by auto-deref
130   --> $DIR/explicit_auto_deref.rs:140:22
131    |
132 LL |     let _ = S2 { s: &*s };
133    |                      ^^ help: try this: `s`
134
135 error: deref which would be done by auto-deref
136   --> $DIR/explicit_auto_deref.rs:156:30
137    |
138 LL |             let _ = Self::S1(&**s);
139    |                              ^^^^ help: try this: `s`
140
141 error: deref which would be done by auto-deref
142   --> $DIR/explicit_auto_deref.rs:157:35
143    |
144 LL |             let _ = Self::S2 { s: &**s };
145    |                                   ^^^^ help: try this: `s`
146
147 error: deref which would be done by auto-deref
148   --> $DIR/explicit_auto_deref.rs:160:21
149    |
150 LL |     let _ = E1::S1(&*s);
151    |                     ^^ help: try this: `s`
152
153 error: deref which would be done by auto-deref
154   --> $DIR/explicit_auto_deref.rs:161:26
155    |
156 LL |     let _ = E1::S2 { s: &*s };
157    |                          ^^ help: try this: `s`
158
159 error: deref which would be done by auto-deref
160   --> $DIR/explicit_auto_deref.rs:179:13
161    |
162 LL |     let _ = (*b).foo;
163    |             ^^^^ help: try this: `b`
164
165 error: deref which would be done by auto-deref
166   --> $DIR/explicit_auto_deref.rs:180:13
167    |
168 LL |     let _ = (**b).foo;
169    |             ^^^^^ help: try this: `b`
170
171 error: deref which would be done by auto-deref
172   --> $DIR/explicit_auto_deref.rs:195:19
173    |
174 LL |     let _ = f_str(*ref_str);
175    |                   ^^^^^^^^ help: try this: `ref_str`
176
177 error: deref which would be done by auto-deref
178   --> $DIR/explicit_auto_deref.rs:197:19
179    |
180 LL |     let _ = f_str(**ref_ref_str);
181    |                   ^^^^^^^^^^^^^ help: try this: `ref_ref_str`
182
183 error: deref which would be done by auto-deref
184   --> $DIR/explicit_auto_deref.rs:207:13
185    |
186 LL |     f_str(&&*ref_str); // `needless_borrow` will suggest removing both references
187    |             ^^^^^^^^ help: try this: `ref_str`
188
189 error: deref which would be done by auto-deref
190   --> $DIR/explicit_auto_deref.rs:208:12
191    |
192 LL |     f_str(&&**ref_str); // `needless_borrow` will suggest removing only one reference
193    |            ^^^^^^^^^^ help: try this: `ref_str`
194
195 error: deref which would be done by auto-deref
196   --> $DIR/explicit_auto_deref.rs:217:41
197    |
198 LL |     let _ = || -> &'static str { return *s };
199    |                                         ^^ help: try this: `s`
200
201 error: aborting due to 33 previous errors
202