]> git.lizzy.rs Git - rust.git/blob - src/test/ui/type-alias-impl-trait/issue-60371.rs
Merge commit 'f2cdd4a78d89c009342197cf5844a21f8aa813df' into sync_cg_clif-2022-04-22
[rust.git] / src / test / ui / type-alias-impl-trait / issue-60371.rs
1 trait Bug {
2     type Item: Bug;
3
4     const FUN: fn() -> Self::Item;
5 }
6
7 impl Bug for &() {
8     type Item = impl Bug; //~ ERROR `impl Trait` in type aliases is unstable
9
10     const FUN: fn() -> Self::Item = || ();
11     //~^ ERROR the trait bound `(): Bug` is not satisfied
12 }
13
14 fn main() {}