This error indicates that a #[non_exhaustive] attribute was incorrectly placed on something other than a struct or enum.
#[non_exhaustive]
Examples of erroneous code:
#[non_exhaustive] trait Foo { }