blob: 86cc5e2c31e8170014f5c25081af499220217e29 [file] [log] [blame]
#![feature(type_alias_impl_trait)]
#![deny(improper_ctypes)]
pub trait Baz { }
impl Baz for () { }
type Qux = impl Baz;
fn assign() -> Qux {}
pub trait Foo {
type Assoc: 'static;
}
impl Foo for () {
type Assoc = Qux;
}
#[repr(transparent)]
pub struct A<T: Foo> {
x: &'static <T as Foo>::Assoc,
}
extern "C" {
pub fn lint_me() -> A<()>; //~ ERROR: uses type `impl Baz`
}
fn main() {}