2019-09-01 17:30:19 -04:00
|
|
|
// check-pass
|
2019-06-03 19:54:28 +01:00
|
|
|
|
2019-07-30 00:11:58 +01:00
|
|
|
#![feature(type_alias_impl_trait)]
|
2019-06-03 19:54:28 +01:00
|
|
|
|
2019-07-30 00:11:58 +01:00
|
|
|
type X = impl Clone;
|
2019-06-03 19:54:28 +01:00
|
|
|
|
|
|
|
fn bar<F: Fn(&i32) + Clone>(f: F) -> F {
|
|
|
|
f
|
|
|
|
}
|
|
|
|
|
|
|
|
fn foo() -> X {
|
2019-09-01 17:30:19 -04:00
|
|
|
bar(|_| ())
|
2019-06-03 19:54:28 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|