1 // compile-flags: -Zsave-analysis
3 #![feature(type_alias_impl_trait)]
5 type Closure = impl FnOnce();
8 || -> Closure { || () }
9 //~^ ERROR: mismatched types
10 //~| ERROR: mismatched types
11 //~| ERROR: expected a `FnOnce<()>` closure, found `()`