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=0.2 required=5.0 tests=BAYES_00,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a369e9bb4bee1413 X-Google-Attributes: gid103376,public From: kilgallen@eisner.decus.org (Larry Kilgallen) Subject: Re: Are unconstrained arrays passed by references? Date: 1999/08/11 Message-ID: <1999Aug11.073146.1@eisner>#1/1 X-Deja-AN: 511417556 X-Nntp-Posting-Host: eisner.decus.org References: <7oomct$t93$1@nnrp1.deja.com> <7opbch$bca$1@nnrp1.deja.com> <37B071C8.FF759493@averstar.com> <7oq77c$1et$1@nnrp1.deja.com> X-Trace: news.decus.org 934371111 18332 KILGALLEN [216.44.122.34] Organization: LJK Software Reply-To: Kilgallen@eisner.decus.org.nospam Newsgroups: comp.lang.ada Date: 1999-08-11T00:00:00+00:00 List-Id: In article <7oq77c$1et$1@nnrp1.deja.com>, Robert Dewar writes: > In article <37B071C8.FF759493@averstar.com>, > Tucker Taft wrote: >> If the subprogram has convention "C" then you can be sure that >> arrays are passed by reference. > > I disagree, this is implementation advice only, not a > requirement of the standard. For example, it would be perfectly > valid to pass a 32 bit packed array as an int (it would not > meet the implementation advice, but it would be valid). Doesn't this depend on the C compiler to which you are interfacing ? I know VAX C can accept an array of 9 bytes passed by value (it spreads the bytes across the registers when running on Alpha). I presume DEC C can do the same thing for the sake of compatibility. The only things I know about C compilers are the ugly things. Larry Kilgallen