C++ Logo

liaison

Advanced search

Re: [wg14/wg21 liaison] Type of u8"" array elements are 'char', but u8'' is 'unsigned char' ?

From: Robert Seacord <rcseacord_at_[hidden]>
Date: Mon, 28 Feb 2022 15:39:40 -0500
If I remember correctly, we voted this paper
http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2653.htm into C23 at the
last meeting so you probably want to refer to this as it changes things.

Thanks,
rCs

On Mon, Feb 28, 2022 at 3:29 PM Steve Downey via Liaison <
liaison_at_[hidden]> wrote:

> Looking at N 2731
> http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2731.pdf to see how
> conversion from source encoding to u8 literal is handled, I notice that
> 6.4.5 String Literals para 6 says "For UTF–8 string literals, the array
> elements have type char", although in 6.4.4.4 Character Constants para 12
> it says "A UTF–8 character constant has type unsigned char."
>
> Is the inconsistency a bug or deliberate?
> _______________________________________________
> Liaison mailing list
> Liaison_at_[hidden]
> Subscription: https://lists.isocpp.org/mailman/listinfo.cgi/liaison
> Link to this post: http://lists.isocpp.org/liaison/2022/02/1009.php
>

Received on 2022-02-28 20:39:52