]> git.lizzy.rs Git - rust.git/blob - tests/ui/lint/lint-ctypes-73251.rs
Auto merge of #106884 - clubby789:fieldless-enum-debug, r=michaelwoerister
[rust.git] / tests / ui / lint / lint-ctypes-73251.rs
1 // check-pass
2
3 #![feature(type_alias_impl_trait)]
4 #![deny(improper_ctypes)]
5
6 pub trait Foo {
7     type Assoc;
8 }
9
10 impl Foo for () {
11     type Assoc = u32;
12 }
13
14 type Bar = impl Foo<Assoc = u32>;
15
16 fn assign() -> Bar {}
17
18 extern "C" {
19     pub fn lint_me() -> <Bar as Foo>::Assoc;
20 }
21
22 fn main() {}