[0/2] : C N2653 char8_t implementation

Message ID 28456f5f-58fa-8dcc-2d44-3d4d4eca944b@honermann.net
Headers
Series : C N2653 char8_t implementation |

Message

Tom Honermann Jan. 8, 2022, 12:42 a.m. UTC
  This series of patches implements the core language features for the 
WG14 N2653 [1] proposal to provide char8_t support in C. These changes 
are intended to align char8_t support in C with the support provided in 
C++20 via WG21 P0482R6 [2].

These patches addresses feedback provided in response to a previous 
submission [3][4].

These changes do not impact default gcc behavior. Per prior feedback by 
Joseph Myers, the existing -fchar8_t and -fno-char8_t options used to 
opt-in to or opt-out of char8_t support in C++ are NOT reused for C. 
Instead, the C related core language changes are enabled when targeting 
C2x. Note that N2653 has not yet been accepted by WG14 for C2x, but the 
patches enable these changes for C2x in order to avoid an additional 
language dialect flag (e.g., -fchar8_t).

Patch 1: Language support
Patch 2: New tests

Tom.

[1]: WG14 N2653
      "char8_t: A type for UTF-8 characters and strings (Revision 1)"
      http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2653.htm

[2]: WG21 P0482R6
      "char8_t: A type for UTF-8 characters and strings (Revision 6)"
      https://wg21.link/p0482r6

[3]: [PATCH 0/3]: C N2653 char8_t implementation
      https://gcc.gnu.org/pipermail/gcc-patches/2021-June/572022.html

[4]: [PATCH 1/3]: C N2653 char8_t: Language support
      https://gcc.gnu.org/pipermail/gcc-patches/2021-June/572023.html
  

Comments

Joseph Myers Jan. 11, 2022, 2:23 a.m. UTC | #1
Please repost these patches after GCC 12 branches (updated as appropriate 
depending on whether the feature is accepted at the two-week Jan/Feb WG14 
meeting, which doesn't yet have an agenda), since we're currently 
stabilizing for the release and so not considering new features.
  
Tom Honermann Jan. 11, 2022, 7:03 p.m. UTC | #2
On 1/10/22 9:23 PM, Joseph Myers wrote:
> Please repost these patches after GCC 12 branches (updated as appropriate
> depending on whether the feature is accepted at the two-week Jan/Feb WG14
> meeting, which doesn't yet have an agenda), since we're currently
> stabilizing for the release and so not considering new features.
>
Thank you, Joseph. Will do!

Tom.