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,174ec7dc941a1068 X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!62.111.101.3.MISMATCH!news.germany.com!storethat.news.telefonica.de!telefonica.de!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail Newsgroups: comp.lang.ada Subject: Re: Factory Pattern From: Georg Bauhaus In-Reply-To: <1185454958.105983.143570@l70g2000hse.googlegroups.com> References: <1185387571.367570.163160@r34g2000hsd.googlegroups.com> <1185432247.046242.24300@o61g2000hsh.googlegroups.com> <1185439242.28126.36.camel@kartoffel> <1185447702.28126.57.camel@kartoffel> <1185454958.105983.143570@l70g2000hse.googlegroups.com> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-Id: <1185461897.28126.94.camel@kartoffel> Mime-Version: 1.0 X-Mailer: Evolution 2.10.1 Date: Thu, 26 Jul 2007 16:58:17 +0200 Organization: Arcor NNTP-Posting-Date: 26 Jul 2007 16:57:48 CEST NNTP-Posting-Host: 8a7358d6.newsspool3.arcor-online.net X-Trace: DXC=Bf\1;6IcNH4nBOkdL^Lo7>McF=Q^Z^V384Fo<]lROoR1^YC2XCjHcb90iD2J On Thu, 2007-07-26 at 06:02 -0700, Maciej Sobczak wrote: > On 26 Lip, 13:01, Georg Bauhaus > wrote: > > > > > Why is being case-insensitive and allowing full Unicode > > > > in identifiers schizophrenic? > > > > > Because the concept of "case" does not apply to all scripts. > > Bingo, but not only. Some scripts do have the concept of "case", but > the mapping between upper-case and lower-case is not 1:1. Or even > better, the *length* of sequence changes with case. This introduces > some funny effects when trying to decide whether two sequences have > the same meaning. What is funny about the effects of a transformation function? I would expect a transformation to result in something that is not identical, but reflecting needs. Just like a calendar date has a number of literals because most of them must follow the local conventions (e.g. in legal documents). This precludes writing a canonical, technical, internal representation in source documents. Insofar as programming is a formal, human activity, I would expect the mode of expression to be somewhere between formal and prosaic. > In the case-insensitive programming language I would > expect that changing the "case" of one character in the identifier > will not change its semantics. How Ada guarantees this for Unicode? Ada guarantees this by way of defining identifiers etc. in the RM. > Or maybe is Ada case-insensitive only in the ASCII subset of Unicode? > Sorry, I don't call it "well-designed". That would indeed be strange. > We can make something case-insensitive in order to *reduce* the number > of characters that are effectively different; and we can provide > support for Unicode in order to *increase* the number of different > characters. Being able to select characters reduces it again. (Computers can help with checking the selection. They are already performing more advanced checks. :-) I think it is quite likely that the large population using ideographic characters will find it easier to use the words that they know when the alternative is to learn English. (I think the transcriptions using Latin characters have never become popular in China.) (Try having us communicate in Japanese. How long will the training take? Slavic languages are already different for those having grown up with one of the Latin-Saxon dialects. Yet at least the grammars have similar structure. Not so with Chinese.) > In my very humble opinion both are bad ideas (even separately). But why? When I saw the Fortress language documents I thought, Oh God, not that again! If my understanding is correct, "a" and "A" in the same local scope are different identifiers, and "_a" with a leading underscore adds bold face characteristics to another a! And they happily reintroduce the white space operator that is so aptly described by Bjarne Stroustrup. (Robert Dewar (Spitbol) was credited by Ralph Griswold (SNOBOL4) for having replaced the white space operator with '?'). Perhaps the Fortress guys think it is cool to be able to write something like a A /= aA Will the computer-denying academics learn that writing programs is *not*, and should not be, the same as writing a math paper? Lazy snobs! Getting them out of their universities and laboratories and have them change a handful of programs written by regular programmers might help. Enough steam for today, sorry! -- Georg