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 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,f1c9515ab067aaea,start X-Google-Attributes: gid103376,public X-Google-Language: Japanese,JIS Path: g2news2.google.com!news4.google.com!news.glorb.com!newsfeed.news2me.com!newsfeed.media.kyoto-u.ac.jp!newsfeed2.dti.ad.jp!mfeed-news!newsgate1.web.ad.jp!news501.nifty.com!not-for-mail From: "Y.Tomino" Newsgroups: comp.lang.ada Subject: Unicode identifier and Wide_Value Date: Fri, 14 Jul 2006 02:46:39 +0900 Organization: @nifty netnews service Message-ID: NNTP-Posting-Host: nttcgi010194.tcgi.nt.adsl.ppp.infoweb.ne.jp Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-2022-JP Content-Transfer-Encoding: 7bit X-Trace: news521.nifty.com 1152812791 5324 219.97.138.194 (13 Jul 2006 17:46:31 GMT) X-Complaints-To: - NNTP-Posting-Date: Thu, 13 Jul 2006 17:46:31 +0000 (UTC) User-Agent: Thunderbird 1.5.0.4 (Windows/20060516) Xref: g2news2.google.com comp.lang.ada:5669 Date: 2006-07-14T02:46:39+09:00 List-Id: Hello. Ada2005 supports Unicode Identifier, and I tried to use it. It's convenience to convert enum-values <=> strings. Wide_Image works, but Wide_Value(Wide_Image(x)) raises Constraint_Error. Test: with Ada.Text_IO; procedure Test is type T is (あ); -- Japanease letter like A I : Wide_String := T'Wide_Image(T'First); S : T := T'Wide_Value(I); begin null; end Test; >gnatmake -gnat05 -gnatW8 test gcc -c -gnat05 -gnatW8 test.adb gnatbind -x test.ali gnatlink test.ali >test raised CONSTRAINT_ERROR : s-valenu.adb:75 explicit raise But bracket literal ["3042"] works correctly. Wide_Image and Wide_Value are OK........ ??? -- YT