TEAM-ADA Archives

Team Ada: Ada Programming Language Advocacy


Options: Use Classic View

Use Proportional Font
Show Text Part by Default
Show All Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Tom Moran <[log in to unmask]>
Sun, 28 Jan 2001 16:14:55 -0800
text/plain (11 lines)
> is tehre a AddressOf() command
> to simulate a pointer for a Standard C or API function call
 X'Access.  But look at your compiler docs.  Looking at the info for one
Ada 95 compiler I see "Ada 'in' parameters map to normal C parameters;
types are converted as necessary for most scalar types.  For non-scalar
types, a pointer at the object is passed to C.  This corresponds to the
normal *struct passing of C.  Ada 'in out' parameter map to *type
parameters in C.  *type parameters can also be mapped to access types or
to System.Address."  Some compilers have a special pragma to let you
pass non-scalars by value rather than reference.  Check your docs.