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.99.170.8 with SMTP id e8mr7183442pgf.85.1503088408781; Fri, 18 Aug 2017 13:33:28 -0700 (PDT) X-Received: by 10.36.123.21 with SMTP id q21mr132697itc.2.1503088408721; Fri, 18 Aug 2017 13:33:28 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!news.swapon.de!weretis.net!feeder6.news.weretis.net!feeder.usenetexpress.com!feeder-in1.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!f16no990341itb.0!news-out.google.com!c139ni1788itb.0!nntp.google.com!m81no648610itb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 18 Aug 2017 13:33:28 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=2601:191:8303:2100:5985:2c17:9409:aa9c; posting-account=fdRd8woAAADTIlxCu9FgvDrUK4wPzvy3 NNTP-Posting-Host: 2601:191:8303:2100:5985:2c17:9409:aa9c References: <79e06550-67d7-45b3-88f8-b7b3980ecb20@googlegroups.com> <9d4bc8aa-cc44-4c30-8385-af0d29d49b36@googlegroups.com> <1395655516.524005222.638450.laguest-archeia.com@nntp.aioe.org> <4527d955-a6fe-4782-beea-e59c3bb69f21@googlegroups.com> <22c5d2f4-6b96-4474-936c-024fdbed6ac7@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Community Input for the Maintenance and Revision of the Ada Programming Language From: Robert Eachus Injection-Date: Fri, 18 Aug 2017 20:33:28 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Xref: news.eternal-september.org comp.lang.ada:47744 Date: 2017-08-18T13:33:28-07:00 List-Id: On Friday, August 11, 2017 at 10:48:39 AM UTC-4, jsqu...@gmail.com wrote: > > On the otherhand Ada.Directories and Ada.Text_IO are woefully outdated.= For example, if you have a computer and you speak a language like Japanese= , French, German, Spanish, etc. think of how frustrating it is when you sim= ply can't open a file with anything other than ASCII in the path. A program= that deals with relative directories might work fine in one directory but = get moved and suddenly fail hopelessly. Poor end-user :( >=20 > My mistake String supports more than just ASCII (Duh), but Asian and othe= r esoteric languages obvious not. There are three decisions about character sets made every time you create A= da source files. It is nice to have them all the same, but people used to = that get their minds wrapped around the axle when it is not true. The thre= e cases are: 1) The character set used to write the Ada parts of the program. 2) The character sets the executing computer will use when interpreting cha= racters and string values. 3) The character sets used by the programmer to express character and strin= g constants. In addition, there are the character sets for the keyboard, the display, an= y printers, etc. Fortunately most printers today can handle mixed characte= r sets if the compiler knows how to prepare listings for them. Also a comp= iler may allow characters in comments which are not allowed elsewhere in th= e source--but it is nice for the character sets in Strings and comments to = match. Compilers can, and do have switches to set the character set used for the A= da code. Technically it is not standard compliant to compile in this mode = for the international standard, but may be fine for National standards. It = is also possible to have switches choose the source and target representati= on for characters and strings. Since the name of a file is represented as = a String, it is quite possible for a compiler to support ShiftJIS as the ch= aracter set for String, and thus for file names. Of course, you need the c= omputer running the program to interpret them the same way... I hope that Ada is (slowly) moving toward UTF-8 as the default--with the em= phasis on slowly. For example, a standard conversion from UTF-8 to Long_Lo= ng_Character and back would be very nice. (What about Long_Character? It = should be Unicode, and if there is any deviation between UTF-16 and Unicode= , stick with Unicode.) Is it possible for you to find an Ada compiler that will allow programs wri= tten in your favorite language and character set? That is a market issue. = Ada has moved in the direction of supporting multiple character sets a lot= better than most standard languages. But if you don't have the vendor sup= port? To take an example from above, you should always be able to pass Shi= ftJIS strings to the file system.* But to write the programs in Ada, you w= ill need a ShiftJIS capable terminal and printer to stay sane. I would ho= pe that Unicode and full ISO 10646 is gradually replacing other Japanese en= codings. * Gotchas: If the second byte of a shift JIS pair is '"', you will need to= put an extra " in when writing the string, with the compiler thinking you = are using Latin-1 or whatever. Similarly high page control codes will have= to be entered by name. The best thing to do is write a program that can c= onvert JIS or Shift JIS source to an 8-bit Ada source string.