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.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,23ca868289d9f0c X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!postnews.google.com!h48g2000cwc.googlegroups.com!not-for-mail From: "cl1" Newsgroups: comp.lang.ada Subject: Re: generic package with procedure paramter gives "not subtype conformant with declaration" Date: 1 Oct 2006 21:46:04 -0700 Organization: http://groups.google.com Message-ID: <1159764364.032190.175700@h48g2000cwc.googlegroups.com> References: <1159738009.962575.108920@i42g2000cwa.googlegroups.com> NNTP-Posting-Host: 66.160.210.89 Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: posting.google.com 1159764369 15501 127.0.0.1 (2 Oct 2006 04:46:09 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Mon, 2 Oct 2006 04:46:09 +0000 (UTC) In-Reply-To: User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en) AppleWebKit/418.9 (KHTML, like Gecko) Safari/419.3,gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: h48g2000cwc.googlegroups.com; posting-host=66.160.210.89; posting-account=MCxsfw0AAABxs2rB6FOIOk-6XLUrvbBM Xref: g2news2.google.com comp.lang.ada:6835 Date: 2006-10-01T21:46:04-07:00 List-Id: tmoran@acm.org wrote: > > > For types, any convention-C access type will work for a void pointer > > > when the values come from C and are never dereferenced by the Ada. > > ... > > Once i store the access in the pointer i no longer need to know > > what type it is. I just need the reference to pass to the C code. > Maybe I'm not understanding but if the values come from C and are > never used by Ada, but merely passed on to other calls on C, why not > just declare them as > type C_Param is new Interfaces.Unsigned_32; > and treat them in Ada as a black box, size 32, content unknown. The values come from ada.