C++ Logo

sg16

Advanced search

[isocpp-sg16] User facing term for "basic character"

From: Corentin <corentin.jabot_at_[hidden]>
Date: Thu, 24 Oct 2024 10:11:26 +0200
Hey folks

A couple of weeks ago in the context of the unit library, we needed to name
a function which returns a sequence of characters composed of elements of
the basic character set in the literal encoding.

Independently of that, I have been meaning (for years at this point) to
offer a set of replacement for ctype functions that are locale independent,
constexpr, and only deal with basic character set elements (and not eof!).

In other programming languages, such a thing would be called ascii_lower,
for example.
But for us , it's not quite right, because ebcdic

This leaves us with
 - using the name `ascii` but produce ebcdic on the platform which deal
with ebcdic
 - using the name `ascii` and always produce ascii, even if the literal
encoding is ebcdic
 - using the name basic, but what does basic mean?
 - using the name "portable", which is not bad in the context of the unit
paper, but not great to refer to text handling functions (portable_lower??)
 - something else???

Any opinions?

Cheers

Received on 2024-10-24 08:11:44