]>
Commit | Line | Data |
---|---|---|
e74abb32 | 1 | #![feature(extern_types)] |
6a06907d XL |
2 | // revisions: min_tait full_tait |
3 | #![feature(min_type_alias_impl_trait)] | |
4 | #![cfg_attr(full_tait, feature(type_alias_impl_trait))] | |
5 | //[full_tait]~^ WARN incomplete | |
e74abb32 XL |
6 | |
7 | #![warn(unused_attributes)] | |
8 | ||
9 | trait Trait { | |
10 | #[inline] //~ WARN `#[inline]` is ignored on constants | |
11 | //~^ WARN this was previously accepted | |
12 | const X: u32; | |
13 | ||
14 | #[inline] //~ ERROR attribute should be applied to function or closure | |
15 | type T; | |
16 | ||
17 | type U; | |
18 | } | |
19 | ||
20 | impl Trait for () { | |
21 | #[inline] //~ WARN `#[inline]` is ignored on constants | |
22 | //~^ WARN this was previously accepted | |
23 | const X: u32 = 0; | |
24 | ||
25 | #[inline] //~ ERROR attribute should be applied to function or closure | |
26 | type T = Self; | |
27 | ||
28 | #[inline] //~ ERROR attribute should be applied to function or closure | |
29 | type U = impl Trait; //~ ERROR could not find defining uses | |
30 | } | |
31 | ||
5869c6ff | 32 | extern "C" { |
e74abb32 XL |
33 | #[inline] //~ ERROR attribute should be applied to function or closure |
34 | static X: u32; | |
35 | ||
36 | #[inline] //~ ERROR attribute should be applied to function or closure | |
37 | type T; | |
38 | } | |
39 | ||
40 | fn main() {} |