Skip to content

Commit ebf2772

Browse files
committed
Add regression test
1 parent ee2158f commit ebf2772

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#![feature(type_alias_impl_trait)]
2+
3+
// this test used to stack overflow due to infinite recursion.
4+
// check-pass
5+
// compile-flags: --edition=2018
6+
7+
use std::future::Future;
8+
9+
fn main() {
10+
let _ = move || async move {
11+
let value = 0u8;
12+
blah(&value).await;
13+
};
14+
}
15+
16+
type BlahFut<'a> = impl Future<Output = ()> + Send + 'a;
17+
fn blah<'a>(_value: &'a u8) -> BlahFut<'a> {
18+
async {}
19+
}

0 commit comments

Comments
 (0)