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.7 required=5.0 tests=BAYES_00,MSGID_RANDY autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,f58edf3a3fc00db X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2000-12-20 01:10:04 PST Path: supernews.google.com!sn-xit-02!sn-xit-03!supernews.com!portc01.blue.aol.com!newsfeed.mathworks.com!news.maxwell.syr.edu!nntp2.deja.com!nnrp1.deja.com!not-for-mail From: Robert Dewar Newsgroups: comp.lang.ada Subject: Re: Interface to C; Storage_Error Date: Wed, 20 Dec 2000 08:55:10 GMT Organization: Deja.com Message-ID: <91ps5d$ibu$1@nnrp1.deja.com> References: <91ondg$lpu$1@nnrp1.deja.com> <91padu$572$1@nnrp1.deja.com> NNTP-Posting-Host: 205.232.38.41 X-Article-Creation-Date: Wed Dec 20 08:55:10 2000 GMT X-Http-User-Agent: Mozilla/4.61 [en] (OS/2; U) X-Http-Proxy: 1.0 x67.deja.com:80 (Squid/1.1.22) for client 205.232.38.41 X-MyDeja-Info: XMYDJUIDrobert_dewar Xref: supernews.google.com comp.lang.ada:3279 Date: 2000-12-20T08:55:10+00:00 List-Id: In article <91padu$572$1@nnrp1.deja.com>, Ted Dennison wrote: > That brings me to the second issue; pragma Import does > essentially th same job as pragma Import_Valued_Procedure. > Check the gnat docs, but it seems wrong to me that they are > being used together. I suggest that if you want to offer advice on GNAT specific pragmas, you read the GNAT documentation, rather than guessing, since a completely wrong guess (as in this case) simply confuses people. One of the troubles with CLA is that a high proportion of the advice here is plain wrong. In this particular case, a cursory check of the GNAT documentation would have found the sentence: Note that it is important to use this pragma in conjunction with a separate pragma Import that specifies the desired convention, since otherwise the default convention is Ada, which is almost certainly not what is required. Incidentally the use of pragma Import_Valued_Procedure is perfectly reasonable in this case, and it is not so easily replaced by pragma Import alone (that's why DEC invented this useful feature for interfacing to C). Sent via Deja.com http://www.deja.com/