From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.107.114.8 with SMTP id n8mr9406192ioc.31.1514461615654; Thu, 28 Dec 2017 03:46:55 -0800 (PST) X-Received: by 10.157.19.100 with SMTP id q33mr757412otq.13.1514461615586; Thu, 28 Dec 2017 03:46:55 -0800 (PST) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.unit0.net!peer03.am4!peer.am4.highwinds-media.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!border1.nntp.dca1.giganews.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!i6no3307121itb.0!news-out.google.com!b73ni12695ita.0!nntp.google.com!i6no3307117itb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 28 Dec 2017 03:46:55 -0800 (PST) In-Reply-To: <0cc30dc8-4528-4e5c-91dd-24dfbe3cbcb2@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=185.30.133.97; posting-account=hya6vwoAAADTA0O27Aq3u6Su3lQKpSMz NNTP-Posting-Host: 185.30.133.97 References: <0cc30dc8-4528-4e5c-91dd-24dfbe3cbcb2@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <96764e4c-48df-4042-845e-12341149bc87@googlegroups.com> Subject: Re: When to use Bounded_String? From: Vincent DIEMUNSCH Injection-Date: Thu, 28 Dec 2017 11:46:55 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Received-Bytes: 1974 X-Received-Body-CRC: 744108394 Xref: reader02.eternal-september.org comp.lang.ada:49671 Date: 2017-12-28T03:46:55-08:00 List-Id: Le jeudi 23 novembre 2017 11:04:12 UTC+1, briot.e...@gmail.com a =C3=A9crit= =C2=A0: > You could use GNATCOLL.Strings, which provide the short-string-optimizati= on: > when a string is shorter than 19 or 23 characters (32 bit and 64 bit syst= ems) then > no allocation takes place. > They also provide a much larger number of operations than standard string= s or > unbounded_strings, are task safe, and handle unicode. Yes, they are really a great improvement. But they would be perfect if : 1. they handled UTF-8 as the de-facto standard encoding, for strings. 2. they could see strings as sequences of 32-bits Unicode Code Points (Wide= _Wide_Characters).