From: Bob Wells #402 <wel@EUROCONTROL.DE>
Subject: "Common" data
Date: Wed, 12 Oct 1994 18:37:08 +0100
Date: 1994-10-12T18:37:08+01:00 [thread overview]
Message-ID: <9410121737.AA28756@eurocontrol.de> (raw)
G'day,
Where abouts in the LRM does it say that I will only have one copy
of the variable T in the following code? This is naturally what you
would expect, that A.New_T_Value and B.New_T_Value would be working
on the same T, but is this defined in the LRM?
This is a trivialization of some comms code delivered to us, and we
wanted to see if the behaviour was defined by the LRM.
---------------------------------------
package Common is
procedure Update_T;
end Common;
package body Common is
T : Integer;
procedure Update_T is
begin
..
code which updates the variable T;
..
end Update_T;
end Common;
---------------------------------------
package A is
procedure New_T_Value;
end A;
with Common;
package body A is
procedure New_T_Value is
begin
Common.Update_T;
end New_T_Value;
end A;
---------------------------------------
package B is
procedure New_T_Value;
end B;
with Common;
package body B is
procedure New_T_Value is
begin
Common.Update_T;
end New_T_Value;
end B;
---------------------------------------
with A;
with B;
procedure Main is
begin
A.New_T_Value;
B.New_T_Value;
end Main;
Any confirmation of this would be greatly appreciated.
Thanks!
@ --------
@ //// - ( G'day! )
@ (o o) --------
@ ----oOO--(_)--OOo--------------------------------------------------------
Bob Wells "For every action there is an equal
and opposite government program."
@ INTERNET: wel@eurocontrol.de CompuServe: 100272,3004
@ The Ada WWW Server is http://lglwww.epfl.ch/Ada/ Team Ada
@ For exciting Ada info enter 'finger wel@s4ecawel.eurocontrol.de'
next reply other threads:[~1994-10-12 17:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
1994-10-12 17:37 Bob Wells #402 [this message]
1994-10-12 14:38 ` "Common" data Robert I. Eachus
1994-10-13 3:21 ` Tucker Taft
1994-10-13 11:47 ` Robert I. Eachus
1994-10-13 13:45 ` Norman H. Cohen
-- strict thread matches above, loose matches on Subject: below --
1994-10-13 13:22 Keith Arthurs
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox