2021-03-12 04:53:51 -06:00
|
|
|
// revisions: min_tait full_tait
|
|
|
|
#![feature(min_type_alias_impl_trait)]
|
|
|
|
#![cfg_attr(full_tait, feature(type_alias_impl_trait))]
|
2019-09-10 12:16:35 -05:00
|
|
|
#![deny(improper_ctypes)]
|
|
|
|
|
|
|
|
type A = impl Fn();
|
|
|
|
|
|
|
|
pub fn ret_closure() -> A {
|
|
|
|
|| {}
|
|
|
|
}
|
|
|
|
|
|
|
|
extern "C" {
|
|
|
|
pub fn a(_: A);
|
2021-07-27 07:14:21 -05:00
|
|
|
//~^ ERROR `extern` block uses type `impl Fn<()>`, which is not FFI-safe
|
2019-09-10 12:16:35 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|