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 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,45b47ecb995e7a3 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-08-14 07:51:43 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!canoe.uoregon.edu!arclight.uoregon.edu!wn4feed!worldnet.att.net!135.173.83.71!wnfilter1!worldnet-localpost!bgtnsc05-news.ops.worldnet.att.net.POSTED!not-for-mail Message-ID: <3B793B96.800A9C8@worldnet.att.net> From: James Rogers X-Mailer: Mozilla 4.76 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Ada Idioms Progress Preview References: <3B6F1B2F.4FC3C833@gsde.hou.us.ray.com> <5ee5b646.0108071819.6e84e33d@posting.google.com> <3_Xc7.45$NM5.84779@news.pacbell.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Tue, 14 Aug 2001 14:51:42 GMT NNTP-Posting-Host: 12.86.33.146 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc05-news.ops.worldnet.att.net 997800702 12.86.33.146 (Tue, 14 Aug 2001 14:51:42 GMT) NNTP-Posting-Date: Tue, 14 Aug 2001 14:51:42 GMT Organization: AT&T Worldnet Xref: archiver1.google.com comp.lang.ada:11917 Date: 2001-08-14T14:51:42+00:00 List-Id: Lutz Donnerhacke wrote: > > * Ole-Hjalmar Kristensen wrote: > >lutz@iks-jena.de (Lutz Donnerhacke) writes: > >> It's not necessary to provide a buffer to hold any possible string of a > >> given type if you can pass complex objects to or from a function. C can > >> only pass primitive types and therefore switched to passing pointers of > >> implicit terminated arrays. > > > >Close, but not quite. C will happily pass records by value. > > Yep, interesting. Tested with a traditional compiler. > > I wonder why C choosed to use inband signaling that heavily. > They could use clear oob signaling for error signaling, array length ... > But they don't. Why? Very strange. You were almost correct in your earlier posting. The old K&R C did not pass structs by value. That was an improvement added in ANSI C. The old K&R C could only pass primitives (int, float, double, etc and pointers) by value. The same restriction appeared for function return values. Jim Rogers Colorado Springs, Colorado USA