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,a1a88c4d509f6381 X-Google-Attributes: gid103376,public From: Robert Dewar Subject: Re: scope and/or parameters (beginner) Date: 1999/04/16 Message-ID: <7f6eeq$tvd$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 466984866 References: <37064309.889106243@news.dsuper.net> <37084459.8616007@rocketmail.com> <370b0c99.1137352783@news.dsuper.net> <37155f01.1945002895@news.dsuper.net> <7f52vj$n90$1@nnrp1.dejanews.com> <7f59oi$tse$1@nnrp1.dejanews.com> <371c4201.2003123297@news.dsuper.net> X-Http-Proxy: 1.0 x7.dejanews.com:80 (Squid/1.1.22) for client 205.232.38.14 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Fri Apr 16 04:31:22 1999 GMT Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.04 [en] (OS/2; I) Date: 1999-04-16T00:00:00+00:00 List-Id: In article <371c4201.2003123297@news.dsuper.net>, fluffy_dong@dsuper.net wrote: > I know that and I am curious as to why the people who > designed Ada made it this way, as opposed to the way that > I described. If there is > no OUT then it would/should not matter what is done to > the value passed because it's not coming back. The reason, as has been explained is for readability and safety of the code. > Therefore there's no harm in allowing the *copy* >inside the ourter routine to be modified, since the > modification will not be copied out. Yes there is harm, this is confusing code, see my previous post. > >Of course the fallacy in that is that the Ada compiler > >(in most cases) is perfectly free to choose to pass > >those parameters by reference instead of > >copy. No, that's not the reason, and indeed for scalars, where this is most likely to arise, the Ada compiler is NOT free to pass by reference > > That's the answer I was looking for, Maybe it is the answer you were looking for, but it is not the right answer! -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own