A deep dive into a subtle C language bug involving bit-field integer promotions. When a bit-field is used in a shift expression, different compilers disagree on whether to promote it to signed or unsigned int. Microsoft compilers treat the bit-field as its declared base type (unsigned), while gcc and clang consider the

Sort: