]> git.lizzy.rs Git - rust.git/blob - src/test/ui/span/pub-struct-field.rs
Merge commit '8da837185714cefbb261e93e9846afb11c1dc60e' into sync-rustfmt-subtree
[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() {}