mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-07 17:18:32 +03:00
b2d132f10e
warn less about non-exhaustive in ffi Bindgen allows generating `#[non_exhaustive] #[repr(u32)]` enums. This results in nonintuitive nonlocal `improper_ctypes` warnings, even when the types are otherwise perfectly valid in C. Adjust for actual tooling expectations by avoiding warning on simple enums with only unit variants. Closes https://github.com/rust-lang/rust/issues/116831