comp.lang.ada
 help / color / mirror / Atom feed
* access variable Q:
@ 1996-06-16  0:00 David Morton
  1996-06-16  0:00 ` Robert Dewar
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: David Morton @ 1996-06-16  0:00 UTC (permalink / raw)



How do I do the following in Ada?

int *ptr;
int i;

ptr = &i;

I know how to do dynamic stuff with an access pointer,
but I can't read anything clear in the RM
about accessing a static variable...

for instance, I have a record that I
want to have access variables  access some of the elements:

type int_ptr is access integer;
type foo is record
	a, b, c : integer;
end record;

bar : foo;

a_ptr := ??????  -- how do I make this point at bar.a  ????

please post to email, in case the news server fails...  :(

-- 
David Morton
 mailto:dmorton@jinx.sckans.edu    // If you use Netscape 2.0,
 205 College, Winfield, KS 67156   // you can click on the mailto: part to reply!
                                   (HINT, HINT)  :)




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1996-06-19  0:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1996-06-16  0:00 access variable Q: David Morton
1996-06-16  0:00 ` Robert Dewar
1996-06-17  0:00 ` David Morton
1996-06-18  0:00 ` Jon S Anthony
1996-06-19  0:00 ` John Herro

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