]> git.lizzy.rs Git - rust.git/blob - src/test/ui/impl-trait/impl-generic-mismatch-ab.rs
Rollup merge of #95504 - jyn514:library-alias, r=Mark-Simulacrum
[rust.git] / src / test / ui / impl-trait / impl-generic-mismatch-ab.rs
1 use std::fmt::Debug;
2
3 trait Foo {
4     fn foo<A: Debug>(&self, a: &A, b: &impl Debug);
5 }
6
7 impl Foo for () {
8     fn foo<B: Debug>(&self, a: &impl Debug, b: &B) { }
9     //~^ ERROR method `foo` has an incompatible type for trait
10 }
11
12 fn main() {}