C, middle-end: Implement C2Y N3747 paper, Integer Sets, v5
Implements the C2Y N3747 paper, allowing signed _BitInt(1) and changing the type of 0wb to _BitInt(1).
This commit implements the C2Y N3747 paper, which modifies the rules for the _BitInt type in C. Previously, signed _BitInt(1) was disallowed, but this change allows it. Also, the type of the literal 0wb is changed from _BitInt(2) to _BitInt(1). These changes are enabled when compiling in C2Y mode.
In Details
This commit implements changes to the C type hierarchy related to _BitInt as defined in the N3747 paper. It modifies build_bitint_type, c_common_signed_or_unsigned_type, and interpret_integer to accommodate the new rules for _BitInt(1). Search terms: GCC _BitInt C2Y integer sets.
For Context
This commit introduces changes to how GCC handles the _BitInt type, a recent extension to the C language that allows programmers to define integer types with a specific number of bits. The changes are driven by the N3747 proposal for the upcoming C2Y standard. The most significant user-visible impact is that signed _BitInt(1) is now allowed and the type of the literal 0wb has changed to _BitInt(1). Search terms: GCC _BitInt C2Y integer sets.