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,2078dddcdcd8d83 X-Google-Attributes: gid103376,public From: bobduff@world.std.com (Robert A Duff) Subject: Re: Warning: Religious naming convention discussion :-) [was: assign help!!] Date: 1997/05/12 Message-ID: #1/1 X-Deja-AN: 241138883 References: <5kjvcv$evt@news.cis.nctu.edu.tw> Organization: The World Public Access UNIX, Brookline, MA Newsgroups: comp.lang.ada Date: 1997-05-12T00:00:00+00:00 List-Id: In article , Robert Dewar wrote: >says Bob Duff, and I agree in theory, but in practice, say pointer to >most people, and then think of a machine address ... it is that >perception of connection that causes confusion. Well, at least we agree "in theory". ;-) In practise, I *like* the word pointer (with it's fairly high-level meaning), and I'm not about to give it up to those who think it means, merely, "machine address". Who are these "most people"? There are a lot of C and C++ programmers in the world, and yes indeed many of them think pointer=machine address. Sigh. They're wrong, of course, since it's not even true in C or C++, much less Pascal or Ada or Lisp or .... To paraphrase a recent quote from you in a different thread: "Get rid of such people, either by educating them, or by getting rid of them." Anybody who's got experience in a language where "pointer" doesn't allow (e.g.) address arithmetic, and anybody who's programmed in a language where "everything's a pointer", can understand the difference. I mean, by your reasoning, we shouldn't call Ada's arrays "arrays", because they might be confused with C arrays, which are a very low-level notion indeed! ;-) (And, by the way, I have no objection to a language with associative arrays calling *those* things arrays, even though some poor, low-level, Ada programmer might think they're getting a contiguous chunk of storage with random access performance. ;-)) So I'm sticking to my meaning of "pointer", which I think is shared by at least a substantial minority of software folk: It's a pointer if it points -- i.e. if you have reference semantics. That is, if you modify what X points to, and what Y points to can see the change, you've got reference semantics. That's why I sometimes say, "So-and-so (an index into an array) points to such-and-such thing (an element of that array)." (In fact, I said such things about array indices when I was programming in assembly language!) - Bob