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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,421baaa91aa096a7 X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!feeder.news-service.com!newsfeed.freenet.de!bolzen.all.de!newsfeed.ision.net!newsfeed2.easynews.net!ision!newsfeed.arcor.de!newsspool1.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Sat, 12 Jul 2008 14:25:43 +0200 From: Georg Bauhaus Reply-To: rm.tsoh-bauhaus@maps.futureapps.de User-Agent: Thunderbird 2.0.0.14 (X11/20080502) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Wide_[Wide_]Character References: <4878950d$0$25515$4d3efbfe@news.sover.net> In-Reply-To: <4878950d$0$25515$4d3efbfe@news.sover.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Message-ID: <4878a2c7$0$6560$9b4e6d93@newsspool3.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 12 Jul 2008 14:25:43 CEST NNTP-Posting-Host: 23996a00.newsspool3.arcor-online.net X-Trace: DXC=`fXk;o[@cJjPKPPVf;4hUjMcF=Q^Z^V3h4Fo<]lROoRa8kFejVhccg5:G2U2g`>Q;FZWd^4>c X-Complaints-To: usenet-abuse@arcor.de Xref: g2news1.google.com comp.lang.ada:1129 Date: 2008-07-12T14:25:43+02:00 List-Id: Peter C. Chapin wrote: > I understand that this doesn't speak to the issue of encoding, but > perhaps that is intended to be left unspecified. In any event it seems > fairly clear that you should be able to store any of 2147483648 values > in a single Wide_Wide_Character variable. Doesn't that mean > Wide_Wide_Character needs to be (at least) 32 bits? package Standard specifize 'Size of Wide_Wide_Character, type Wide_Wide_Character is (nul, soh ... Hex_7FFFFFFE, Hex_7FFFFFFF); for Wide_Wide_Character'Size use 32; Annex B has some hints as to the internal representation: 43.a/2 Discussion: The C types wchar_t and char16_t seem to be the same. However, wchar_t has an implementation-defined size, whereas char16_t is guaranteed to be an unsigned type of at least 16 bits. Also, char16_t and char32_t are encouraged to have UTF-16 and UTF-32 representations; that means that they are not directly the same as the Ada types, which most likely don't use any UTF encoding. Isn't this just like the RM not specifying the bit layout of numeric objects? -- Georg Bauhaus Y A Time Drain http://www.9toX.de