]> git.lizzy.rs Git - rust.git/blob - src/test/ui/unboxed-closures/issue-53448.rs
Rollup merge of #86828 - lambinoo:67441-const-fn-copied-take-replace, r=joshtriplett
[rust.git] / src / test / ui / unboxed-closures / issue-53448.rs
1 #![feature(unboxed_closures)]
2
3 trait Lt<'a> {
4     type T;
5 }
6 impl<'a> Lt<'a> for () {
7     type T = ();
8 }
9
10 fn main() {
11     let v: <() as Lt<'_>>::T = ();
12     let f: &mut dyn FnMut<(_,), Output = ()> = &mut |_: <() as Lt<'_>>::T| {};
13     //~^ ERROR: the size for values of type `<() as Lt<'_>>::T` cannot be known
14     f(v);
15 }