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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,10444cff97404845 X-Google-Attributes: gid103376,public From: Brian Rogoff Subject: Re: C like op= proposal Date: 1999/08/18 Message-ID: #1/1 X-Deja-AN: 514545561 References: <37B7D172.DCE02FFA@Maths.UniNe.CH> <87emh2l218.fsf@antinea.enst.fr> <7pd6th$2qj$1@nnrp1.deja.com> <7pecjk$std$1@nnrp1.deja.com> Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: nntp1.ba.best.com 935035495 199 bpr@206.184.139.136 MIME-Version: 1.0 Newsgroups: comp.lang.ada Date: 1999-08-18T00:00:00+00:00 List-Id: On Wed, 18 Aug 1999, Robert Dewar wrote: > The pseudo-variable proposal seems entirely horrible to me, and > indeed was not discussed at all. I can see all kinds of abuse > and very little gain from this syntactic vinegar :-) ROTFL! That little expression (syntactic vinegar) was the high point of a bland day. Is that an original Dewarism? > The idea of the evaluation of the right hand side being tied > in semantically to the evaluation of the left hand side like > this seems quite nasty to me, a real confusion in the > fundamental semantics of assignment. Right now the semantics > attributes of assignment are purely inherited, and you really > want to keep things this way. > > Maybe I missed something, but I did not see any significant > support for this particular notion, the discussion was almost > all about the much cleaner (though still fraught with > problems)+= type notation. > > I consider a renaming to be much cleaner for a reader than > the use of your pseudo-variable (the latter is just syntactic > sugar/vinegar for the former presumably???) You presume correctly. I haven't seen the original language which did this, Mode, since I think most of the docs are in Finnish. I saw this idea described in Markku Sakkinen's C++ critique, and I thought it was a neat idea. Some people like things like this, some don't. Obviously, I'm not so dense that I find I = I + 1 and the like to be a problem, but for complex array operations like the example Gautier presented and other such things, I find this notation much easier reading than renaming. If there are nasty semantics issues, and great potential for misuse, that's another issue. I wonder if C and C++ programmers find this stuff more readable? I'm certainly in that category myself, meaning that I write C and C++ code (and enjoy it!) even though in those cases that I use C I would generally prefer Ada given the choice. A more general point about "readability" is that its a pretty vague notion, and I sometimes find Ada's verbosity a detriment to readability. -- Brian