Date: Thu, 23 Sep 2021 11:10:16 +0000
> -----Original Message-----
> From: SG16 <sg16-bounces_at_lists.isocpp.org> On Behalf Of Jens Maurer via SG16
> Sent: 23 September 2021 11:18
> To: Corentin <corentin.jabot_at_gmail.com>
> > "Obviously broken" is a rather big claim in the absence of suitable
> alternatives.
> > I believe the use of the IANA registry is motivated by the paper and
> previous polls.
>
> I think the polls are are not sufficiently precise to argue for the case
> that what the IANA table describes (by implication) as a narrow encoding
> cannot be re-used to designate a wide encoding trivially derived from the
> narrow encoding.
>
This is a good thing.
If I:
1. Obtain the wide literal encoding, E, with the P1885 facility
2. Obtain a wide string literal.
3. Memory copy the string literal into a byte array.
4. Ask an external library [1] "is this byte array validly encoded with this encoding, E".
Then the answer should either be, "yes", or "the external library doesn't recognise the encoding".
Having an 8-bit encoding as your wide literal encoding is nonsense unless your wchar_t is an 8-bit type.
Best regards,
Peter
[1] Because we still don't have a standard encoding facility.
> From: SG16 <sg16-bounces_at_lists.isocpp.org> On Behalf Of Jens Maurer via SG16
> Sent: 23 September 2021 11:18
> To: Corentin <corentin.jabot_at_gmail.com>
> > "Obviously broken" is a rather big claim in the absence of suitable
> alternatives.
> > I believe the use of the IANA registry is motivated by the paper and
> previous polls.
>
> I think the polls are are not sufficiently precise to argue for the case
> that what the IANA table describes (by implication) as a narrow encoding
> cannot be re-used to designate a wide encoding trivially derived from the
> narrow encoding.
>
This is a good thing.
If I:
1. Obtain the wide literal encoding, E, with the P1885 facility
2. Obtain a wide string literal.
3. Memory copy the string literal into a byte array.
4. Ask an external library [1] "is this byte array validly encoded with this encoding, E".
Then the answer should either be, "yes", or "the external library doesn't recognise the encoding".
Having an 8-bit encoding as your wide literal encoding is nonsense unless your wchar_t is an 8-bit type.
Best regards,
Peter
[1] Because we still don't have a standard encoding facility.
Received on 2021-09-23 06:10:27