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

enum size lint #14300

Merged
merged 4 commits into from
May 26, 2014
Merged

enum size lint #14300

merged 4 commits into from
May 26, 2014

Commits on May 23, 2014

  1. Configuration menu
    Copy the full SHA
    3f8cc16 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f122ad0 View commit details
    Browse the repository at this point in the history
  3. rustc: add a lint for large enum variants

    It can be easy to accidentally bloat the size of an enum by making one variant
    larger than the others. When this happens, it usually goes unnoticed. This
    commit adds a lint that can warn when the largest variant in an enum is more
    than 3 times larger than the second-largest variant. This requires a little
    bit of rejiggering, because size information is only available in trans, but
    lint levels are only available in the lint context.
    
    It is allow by default because it's pretty noisy, and isn't really *that*
    undesirable.
    
    Closes #10362
    emberian committed May 23, 2014
    Configuration menu
    Copy the full SHA
    c327080 View commit details
    Browse the repository at this point in the history
  4. 9 Configuration menu
    Copy the full SHA
    d8467e2 View commit details
    Browse the repository at this point in the history