]> git.lizzy.rs Git - rust.git/blob - src/test/ui/type-alias-impl-trait/incoherent-assoc-imp-trait.rs
Merge commit 'cd4810de42c57b64b74dae09c530a4c3a41f87b9' into libgccjit-codegen
[rust.git] / src / test / ui / type-alias-impl-trait / incoherent-assoc-imp-trait.rs
1 // Regression test for issue 67856
2
3 #![feature(unboxed_closures)]
4 #![feature(type_alias_impl_trait)]
5 #![feature(fn_traits)]
6
7 trait MyTrait {}
8 impl MyTrait for () {}
9
10 impl<F> FnOnce<()> for &F {
11     //~^ ERROR conflicting implementations
12     //~| ERROR type parameter `F` must be used
13     type Output = impl MyTrait;
14     extern "rust-call" fn call_once(self, _: ()) -> Self::Output {}
15 }
16 fn main() {}