Bug 92182 - No way to silence ''A::TKind' is too small to hold all values of 'enum Kind''
Summary: No way to silence ''A::TKind' is too small to hold all values of 'enum Kind''
Status: RESOLVED DUPLICATE of bug 61414
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 9.1.0
: P3 normal
Target Milestone: ---
Assignee: Marek Polacek
URL:
Keywords: diagnostic
Depends on:
Blocks: 44209
  Show dependency treegraph
 
Reported: 2019-10-22 19:30 UTC by Dávid Bolvanský
Modified: 2019-10-29 17:44 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2019-10-22 00:00:00


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dávid Bolvanský 2019-10-22 19:30:40 UTC
enum Kind : unsigned {
    Y = 0x0,
    N = 0x1,
    Z = 0x2,
  };


struct A {
    Kind TKind : 2;
};


gcc file.c

warning: 'A::TKind' is too small to hold all values of 'enum Kind'


This warning has no flag so we cannot use -Wno-XXX. Only option to silence this warning is '-w'.
Comment 1 Marek Polacek 2019-10-22 19:36:44 UTC
Confirmed.  I'll add something.
Comment 2 Eric Gallager 2019-10-29 17:44:43 UTC
I think this is a dup of bug 61414

*** This bug has been marked as a duplicate of bug 61414 ***