Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clippy: enum with no variants (clippy:empty-enum) in generated code #16

Open
akloboucnik opened this issue Dec 22, 2018 · 0 comments
Open
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@akloboucnik
Copy link
Contributor

Clippy with -- -W clippy::pedantic produces $subj error on generated code if no env_prefix is configured

Clippy output:

    Checking configure_me_user v0.1.0 (<path>/configure_me_user)
warning: enum with no variants
  --> <path>/configure_me_user/target/debug/build/configure_me_user-72c791d01889789c/out/configure_me_config.rs:46:1
   |
46 | pub enum EnvParseError {}
   | ^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: `-W clippy::empty-enum` implied by `-W clippy::pedantic`
help: consider using the uninhabited type `!` or a wrapper around it
  --> <path>/configure_me_user/target/debug/build/configure_me_user-72c791d01889789c/out/configure_me_config.rs:46:1
   |
46 | pub enum EnvParseError {}
   | ^^^^^^^^^^^^^^^^^^^^^^^^^
   = help: for further information visit https://rust-lang-nursery.github.io/rust-clippy/master/index.html#empty_enum
@Kixunil Kixunil added bug Something isn't working good first issue Good for newcomers labels Aug 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants