Closed
Description
When trying to reexport the variants of a private enum, a diagnostic is emitted for each variant pointing always at the same reexport span, making it too verbose:
error: variant `Variant1` is private, and cannot be reexported, consider declaring its enum as `pub`
--> file.rs:12:9
|
12 | pub use self::Enum::*;
| ^^^^^^^^^^^^^
(...)
error: variant `VariantN` is private, and cannot be reexported, consider declaring its enum as `pub`
--> file.rs:12:9
|
12 | pub use self::Enum::*;
| ^^^^^^^^^^^^^
Ideally there would be only one diagnostic emitted, with an extra span pointing at the definition of Enum
to suggest making it public.