Groups | Search | Server Info | Login | Register


Groups > comp.lang.ada > #59565

Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling)

From Nicolas Paul Colin de Glocester <Spamassassin@irrt.De>
Newsgroups comp.lang.ada, fr.comp.lang.ada
Subject Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling)
Date 2025-09-02 19:40 +0200
Organization A noiseless patient Spider
Message-ID <4248d82b-d759-b5d2-aa45-e4c0e26c81e5@insomnia247.nl> (permalink)
References <op.vhrad6mjule2fv@garhos> <a8156fc2-bfbd-8199-b440-0ca9192d6936@insomnia247.nl> <10974d1$jn0e$1@dont-email.me>

Cross-posted to 2 groups.

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

Alex // nytpu wrote during this decade, specifically today:
|---------------------------------------------------------------------------|
|"I can't find any of my old writing on it so I've rewritten it             |
|here lol."                                                                 |
|---------------------------------------------------------------------------|

Dear Alex:

A teammate had once solved a problem but he had forgotten how he
solved it. So he has queried a search engine. So it showed him a
webpage with a perfect solution --- a webpage written by him!

I recommend searching for that old writing about Unicode: perhaps it
has more details than this comp.lang.ada thread, or perhaps a
perspective has been changed in an interesting way. Even if there is
no difference, perhaps it is in a directory with other missing files
which need to be backed up!

|---------------------------------------------------------------------------|
|"If you use Latin-1 or Windows-1252 or some weird                          |
|regional encoding everyone will hate you, and if you restrict inputs to    |
|7-bit ASCII everyone will hate you too lol.  And people will get annoyed   |
|if you use UTF-16 or UTF-32 instead of UTF-8 as the interchange/storage    |
|format in a new program."                                                  |
|---------------------------------------------------------------------------|

I quote Usenet articles in a way which does not endear me to
persons. Not everyone reacts in the same way. OC Systems asked me how
do I draw those boxes.

I advocate Ada which also does not endear me to persons.

|---------------------------------------------------------------------------|
|"[. . .]                                                                   |
|                                                                           |
|I personally use Wide_Wide_<> for everything just because it's more        |
|convenient to have more useful built-in string functions, and it makes     |
|dealing with input/output encoding much easier later (detailed below).     |
|                                                                           |
|[. . .]                                                                    |
|                                                                           |
|I'm unfortunate enough to know most of the nuances of Unicode but I        |
|won't subject you to it, but a lot of the statements in your collection    |
|are a bit oversimplified (UCS-4 has a number of additional differences     |
|from UTF-32 regarding "valid encodings", [. . .]                           |
|[. . .]"                                                                   |
|---------------------------------------------------------------------------|

Thanks for this feedback and more will be as welcome as can be. I
quoted examples of what I found in this newsgroup. This newsgroup used
not have many statements with explicit references to "UTF-32" or
"UTF32" or "UCS-4" which differ overwhelmingly from what I quoted
during the previous week.

|---------------------------------------------------------------------------|
|"Also, I just stumbled across Ada.Strings.Text_Buffers which seems to be   |
|new to Ada 2022, makes "string builder" stuff much more convenient         |
|because you can write text using any of Ada's string types and then get    |
|a string in whatever encoding you want [. . .]                             |
|[. . .]"                                                                   |
|---------------------------------------------------------------------------|

Package Ada.Strings.Text_Buffers does not support UCS-4.

|---------------------------------------------------------------------------|
|"Note that there is zero chance in hell that UTF-32 will ever be adopted as|
|an interchange or storage encoding (except in isolated singular corporate  |
|apps *maybe*), so UTF-32 being used should purely be an internal           |
|implementation detail: incoming text in whatever encoding gets converted to|
|it and outgoing text will always get converted from it."                   |
|---------------------------------------------------------------------------|

One can know but what one can too optimistically know can be
false. Character sets or encodings used to be subjects of unfulfilled
expectations.

I can say that for now, UTF-8 is enough for a particular application.

Deadly Head did not have the same luck.

|---------------------------------------------------------------------------|
|"The encodings used by                                                     |
|Text_IO are mostly (but not entirely) based off of the `-gnatW` flag, which|
|is configuring the encoding of THE PROGRAM'S SOURCE CODE."                 |
|---------------------------------------------------------------------------|

GNAT has many switches. It could easily gain more switches.

Sincères salutations.



Nicolas Paul Colin de Glocester

Back to comp.lang.ada | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Nicolas Paul Colin de Glocester <Spamassassin@irrt.De> - 2025-08-31 19:39 +0200
  Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Kevin Chadwick <kc-usenet@chadwicks.me.uk> - 2025-08-31 21:23 +0000
    Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Nicolas Paul Colin de Glocester <Spamassassin@irrt.De> - 2025-08-31 23:27 +0200
  Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Alex // nytpu <nytpu@example.invalid> - 2025-09-02 10:01 -0600
    Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Nicolas Paul Colin de Glocester <Spamassassin@irrt.De> - 2025-09-02 19:40 +0200
      Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2025-09-02 11:49 -0700
        Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Nicolas Paul Colin de Glocester <Spamassassin@irrt.De> - 2025-09-02 21:27 +0200
          Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2025-09-02 13:02 -0700
    Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Nicolas Paul Colin de Glocester <Spamassassin@irrt.De> - 2025-09-02 19:42 +0200
      Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Alex // nytpu <nytpu@example.invalid> - 2025-09-02 13:15 -0600
        Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Nicolas Paul Colin de Glocester <Spamassassin@irrt.De> - 2025-09-02 21:50 +0200
    Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> - 2025-09-02 20:08 +0200
      Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Alex // nytpu <nytpu@example.invalid> - 2025-09-02 13:13 -0600
    Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Lawrence D’Oliveiro <ldo@nz.invalid> - 2025-09-02 22:56 +0000
      Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Alex // nytpu <nytpu@example.invalid> - 2025-09-02 18:20 -0600
        Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Lawrence D’Oliveiro <ldo@nz.invalid> - 2025-09-03 04:10 +0000
          Re: Ada 202x; 2022; and 2012 and Unicode package (UTF-nn encodings handling) Alex // nytpu <nytpu@example.invalid> - 2025-09-03 11:25 -0600

csiph-web