]> git.lizzy.rs Git - rust.git/blob - src/test/ui/span/pub-struct-field.rs
Rollup merge of #87922 - Manishearth:c-enum-target-spec, r=nagisa,eddyb
[rust.git] / src / test / ui / span / pub-struct-field.rs
1 // Regression test for issue #26083 and #35435
2 // Test that span for public struct fields start at `pub`
3
4 struct Foo {
5     bar: u8,
6     pub bar: u8, //~ ERROR is already declared
7     pub(crate) bar: u8, //~ ERROR is already declared
8 }
9
10 fn main() {}