This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Help with bit-field semantics in C and C++


"Steven L. Zook" <SLZook@Qualstar.com> writes:

| What would happen in this case?
| 
| enum eSparse { One = 1, Two = 2, Four = 4, Eight = 8 };
| eSpare Sparse = ( eSparse )0x0FFFF;

I guess I don't understand your question.  The smallest bit-field that
can represent One and Eight is 4 bits wide.  Right?

-- Gaby


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]