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,e0e90ec4aca40043 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-07-30 22:24:59 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!netnews.com!wn1feed!worldnet.att.net!135.173.83.71!wnfilter1!worldnet-localpost!bgtnsc06-news.ops.worldnet.att.net.POSTED!not-for-mail From: "David Thompson" Newsgroups: comp.lang.ada References: Subject: Re: Re[2]: Ada The Best Language? X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2615.200 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2615.200 Message-ID: Date: Tue, 31 Jul 2001 05:24:58 GMT NNTP-Posting-Host: 12.89.128.124 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc06-news.ops.worldnet.att.net 996557098 12.89.128.124 (Tue, 31 Jul 2001 05:24:58 GMT) NNTP-Posting-Date: Tue, 31 Jul 2001 05:24:58 GMT Organization: AT&T Worldnet Xref: archiver1.google.com comp.lang.ada:10826 Date: 2001-07-31T05:24:58+00:00 List-Id: Ted Dennison wrote in message news:fqj57.23735$Kf3.319906@www.newsranger.com... ... > I'm sorry to answer for the troll you're chasing after, but the answer to that > depends on what you consider a pointer. You can certianly make array-based > objects in C without using dynamic allocation. However, every array in C is > basicly a chunk of memory and a pointer with a preset "[]" operation for > performing pointer math on it. In that sense, you can't even have an array in C > without using a pointer. Nit: in BCPL and B there was a real pointer for each array variable; in C such a pointer is instead formed "on demand" -- when you reference an array (except 2 special cases, 3 in C++) it is silently converted to a pointer to the first element, often called "decay", and subscripting [] is actually defined on this resulting pointer, so yes you are "using" a pointer even though it wasn't stored. And when you declare a function(subprogram) (formal)parameter as an array, it actually declares a pointer instead, which can be passed by-value from a decayed array, and used to access it. (And subscripting is commutative!) This evolution is described in Dennis Ritchie's ACM2HOPL paper, also available on http://cm.bell-labs.com/cm/cs/who/dmr/ -- - David.Thompson 1 now at worldnet.att.net