* From C to Ada
@ 1989-07-04 19:03 Krishan M Nainani
0 siblings, 0 replies; only message in thread
From: Krishan M Nainani @ 1989-07-04 19:03 UTC (permalink / raw)
Hi,
In converting some C code to Ada I came across a difficulty.
In C, I pass the address of a structure (any structure) to a
routine that doesn't care what the structure is. The structure
is defined in this higher-level program which contains the
procedure call. For example :
struct stype { int a,b,c; float d,e,f; } a_struct;
x = func_name(&a_struct);
/* BTW, in "func_name" I store the structure contents in
bytes by casting (char *). */
In designing the low-level routine (in which this function
is encoded), I was wondering if I could pass the address of
a structure as I do above in C.
If not, then I would have to use a generic package with a
private parameter.
******************************************************************
Also, thanks to everyone who sent me replied to my last
mail message regarding questions on C -> Ada.
******************************************************************
Krishan Nainani. reply-to: tfrancis@wpi.wpi.edu
------------------------------------------------------------
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1989-07-04 19:03 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1989-07-04 19:03 From C to Ada Krishan M Nainani
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox