blob: 7112719a9f284edba418e812a87e22aadea96203 [file] [log] [blame]
//@edition: 2021
#![allow(unused)]
#![allow(clippy::struct_field_names)]
#![warn(clippy::misnamed_getters)]
// Edition 2021 specific check, where `unsafe` blocks are not required
// inside `unsafe fn`.
union B {
a: u8,
b: u8,
}
impl B {
unsafe fn a(&self) -> &u8 {
//~^ misnamed_getters
&self.a
}
}
fn main() {
// test code goes here
}