]> git.lizzy.rs Git - rust.git/blob - tests/ui/traits/issue-97576.rs
Rollup merge of #106701 - ibraheemdev:sync-sender-spin, r=Amanieu
[rust.git] / tests / ui / traits / issue-97576.rs
1 struct Foo {
2     bar: String,
3 }
4
5 impl Foo {
6     pub fn new(bar: impl ToString) -> Self {
7         Self {
8             bar: bar.into(), //~ ERROR the trait bound `String: From<impl ToString>` is not satisfied
9         }
10     }
11 }
12
13 fn main() {}