rust/tests/ui/impl-trait/universal-two-impl-traits.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

17 lines
304 B
Rust
Raw Normal View History

use std::fmt::Debug;
fn foo(x: impl Debug, y: impl Debug) -> String {
let mut a = x;
2017-11-20 06:13:27 -06:00
a = y; //~ ERROR mismatched
format!("{:?}", a)
}
trait S<T> {}
fn much_universe<T: S<impl Debug>, U: IntoIterator<Item = impl Iterator<Item = impl Clone>>>(
_: impl Debug + Clone,
) {
}
fn main() {}