------- Comment #3 from jakub at gcc dot gnu dot org  2007-12-11 12:59 -------
Actually, I'm not sure what type the shifts are supposed to be done with,
because C++ says that only bitfields smaller than int/unsigned int are
promoted.
"An rvalue for an integral bit-field (9.6) can be converted to an rvalue of
type int if int can represent all the values of the bit-field; otherwise, it
can be converted to unsigned int if unsigned int can represent all the values
of the bit-field. If the bit-field is larger yet, no integral promotion applies
to it."
So, is the shift supposed to be done in the base type of the bitfield, or in a
type with bitfield's precision?


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33819

Reply via email to