summaryrefslogtreecommitdiffstats
path: root/src/test/ui/stability-attribute/stability-attribute-issue-43027.rs
blob: 3f4fdfd0180ed2587cf5c6cf685a891affcb69ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// check-pass
#![feature(staged_api)]
#![stable(feature = "test", since = "0")]

#[stable(feature = "test", since = "0")]
pub struct A<T>(pub T);

#[stable(feature = "test", since = "0")]
pub struct B<T>(#[stable(feature = "test", since = "0")] pub T);

fn main() {
    // Make sure the field is used to fill the stability cache
    A(0).0;
    B(0).0;
}