Gilnaa / memoffset

offsetof for Rust
MIT License
224 stars 29 forks source link

clippy: Suppress `identity_op` lint. #82

Closed waywardmonkeys closed 11 months ago

waywardmonkeys commented 11 months ago

This code is for tests and is to line up and draw attention to the offsets. Better to suppress than eliminate.

RalfJung commented 11 months ago

This doesn't seem to work on our oldest supported Rust version, unfortunately.

waywardmonkeys commented 11 months ago

This doesn't seem to work on our oldest supported Rust version, unfortunately.

I've re-formulated it and we'll see if that works!

waywardmonkeys commented 11 months ago

Could probably clean up all of the #[cfg(allow_clippy)] code by using cfg_attr ... but probably not as part of this PR.

RalfJung commented 11 months ago

That works, thanks!