comp.lang.ada
 help / color / mirror / Atom feed
From: "Hibou57 (Yannick Duchêne)" <yannick_duchene@yahoo.fr>
Subject: Re: C interface using a record with discriminant and representation clauses
Date: Sat, 4 Jul 2009 20:17:43 -0700 (PDT)
Date: 2009-07-04T20:17:43-07:00	[thread overview]
Message-ID: <f728e329-f21b-4d15-9ae4-3e296e904992@i6g2000yqj.googlegroups.com> (raw)
In-Reply-To: 4b0ca7ca-e84c-43a6-b3d3-6793d54da91b@z14g2000yqa.googlegroups.com

An anwser here :

http://www.adapower.com/index.php?Command=Class&ClassID=Advanced&CID=228
says (at the end):
> You need rep specs to handle tricky and unusual cases such as:
>
> * Mapping Ada record types with a discriminant and a variant part onto
>   C unions.  This can be made to work as long as the C type has a member
>   that can serve as the discriminant; most sensibly designed C code does.
>
> [...]
>
> If you use rep specs, you should not need pragma Convention, and vice versa.

So this suggest that representation specs and pragma convention should
not be used simultaneously, as I've done due to some doubts.

Using representation specs is Ok, but the pragma Convention is to be
removed (will be done in a minute).



      reply	other threads:[~2009-07-05  3:17 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-30 23:01 C interface using a record with discriminant and representation clauses Hibou57 (Yannick Duchêne)
2009-06-30 23:38 ` Hibou57 (Yannick Duchêne)
2009-07-05  3:17   ` Hibou57 (Yannick Duchêne) [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox