]> git.lizzy.rs Git - rust.git/blob - src/test/ui/traits/suggest-deferences/issue-62530.stderr
Merge commit 'a5d597637dcb78dc73f93561ce474f23d4177c35' into clippyup
[rust.git] / src / test / ui / traits / suggest-deferences / issue-62530.stderr
1 error[E0277]: the trait bound `&String: SomeTrait` is not satisfied
2   --> $DIR/issue-62530.rs:13:26
3    |
4 LL |     takes_type_parameter(&string);  // Error
5    |     -------------------- ^^^^^^^
6    |     |                    |
7    |     |                    the trait `SomeTrait` is not implemented for `&String`
8    |     |                    help: consider adding dereference here: `&*string`
9    |     required by a bound introduced by this call
10    |
11 note: required by a bound in `takes_type_parameter`
12   --> $DIR/issue-62530.rs:4:44
13    |
14 LL | fn takes_type_parameter<T>(_x: T) where T: SomeTrait {}
15    |                                            ^^^^^^^^^ required by this bound in `takes_type_parameter`
16
17 error: aborting due to previous error
18
19 For more information about this error, try `rustc --explain E0277`.