summaryrefslogtreecommitdiffstats
path: root/tests/ui/type-alias-impl-trait/issue-63263-closure-return.rs
blob: 7414611a748936fb6797b9175a04f0176ca32558 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// Regression test for issue #63263.
// Tests that we properly handle closures with an explicit return type
// that return an opaque type.

// check-pass

#![feature(type_alias_impl_trait)]

pub type Closure = impl FnOnce();

fn main() {
    || -> Closure { || () };
}