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,LOTS_OF_MONEY autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,c9a5d6b3975624e1 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-10-07 12:52:18 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!canoe.uoregon.edu!arclight.uoregon.edu!wn12feed!wn14feed!worldnet.att.net!208.49.253.98!newsfeed.news2me.com!west.cox.net!cox.net!newsfeed1.earthlink.net!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!newsread2.prod.itd.earthlink.net.POSTED!not-for-mail Message-ID: <3DA1E5ED.9030702@acm.org> From: Jeffrey Carter User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.0.0) Gecko/20020530 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: OO in Ada References: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Date: Mon, 07 Oct 2002 19:52:19 GMT NNTP-Posting-Host: 63.184.105.107 X-Complaints-To: abuse@earthlink.net X-Trace: newsread2.prod.itd.earthlink.net 1034020339 63.184.105.107 (Mon, 07 Oct 2002 12:52:19 PDT) NNTP-Posting-Date: Mon, 07 Oct 2002 12:52:19 PDT Organization: EarthLink Inc. -- http://www.EarthLink.net Xref: archiver1.google.com comp.lang.ada:29571 Date: 2002-10-07T19:52:19+00:00 List-Id: Matthew Heaney wrote: > "SteveD" wrote in message > news:JVrn9.40015$FO4.9224@sccrnsc03... > >>In C++ there is a hidden "this" pointer quietly hiding in the background >>that you must be very much aware of (if you're doing any serious >>programming). In Ada this is an explicit variable passed into the >>procedure. > > > This is also true in Ada, wrt passing unconstrained arrays: > > procedure Op (S : String) is > > You're actually passing a descriptor on the stack, which contains info about > the string's length and index range. So here there is "hidden" information > being passed too, not unlike an implicit this-ptr in C++. How this is passed is implementation dependent. Some implementations may work as indicated, but others may simply pass an address. Some may pass a copy of the actual parameter. -- Jeff Carter "Have you gone berserk? Can't you see that that man is a ni?" Blazing Saddles