Skip to content

Commit 2355b34

Browse files
committed
Add test of inner attribute inside struct/enum
1 parent 4e8fb74 commit 2355b34

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

src/test/ui/attributes/item-attributes.rs

+18
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,24 @@ mod test_attr_inner {
102102
// This is an attribute of mod m
103103
#![rustc_dummy = "val"]
104104
}
105+
106+
pub struct S {
107+
#![rustc_dummy = "val"]
108+
}
109+
110+
pub union U {
111+
#![rustc_dummy = "val"]
112+
113+
_private: (),
114+
}
115+
116+
pub enum E {
117+
#![rustc_dummy = "val"]
118+
119+
Variant {
120+
#![rustc_dummy = "val"]
121+
}
122+
}
105123
}
106124

107125
mod test_attr_inner_then_outer {

0 commit comments

Comments
 (0)