Add a regression test for #53457

This commit is contained in:
varkor 2019-06-03 19:54:28 +01:00
parent 7840a0b753
commit 41dd21a9bc

View File

@ -0,0 +1,15 @@
// run-pass
#![feature(existential_type)]
existential type X: Clone;
fn bar<F: Fn(&i32) + Clone>(f: F) -> F {
f
}
fn foo() -> X {
bar(|x| ())
}
fn main() {}