mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-01 12:37:37 +00:00
19 lines
256 B
Rust
19 lines
256 B
Rust
//@ edition:2018
|
|
//@ check-pass
|
|
|
|
#![feature(type_alias_impl_trait)]
|
|
|
|
type Tait = impl AsyncFn();
|
|
#[define_opaque(Tait)]
|
|
fn tait() -> Tait {
|
|
|| async {}
|
|
}
|
|
|
|
fn foo(x: impl AsyncFn()) -> impl AsyncFn() {
|
|
x
|
|
}
|
|
|
|
fn param<T: AsyncFn()>() {}
|
|
|
|
fn main() {}
|