From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a4cc6fdc99d3fe2a X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-05-26 12:16:37 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!npeer.kpnqwest.net!EU.net!Norway.EU.net!uninett.no!romeo.dax.net!juliett.dax.net!not-for-mail Message-ID: <3B10011D.13372A87@spam-block.gmx.li> From: Aron Felix Gurski Organization: =?iso-8859-1?Q?Br=F6derna=20Lejonhj=E4rta?= X-Mailer: Mozilla 4.76 [en] (X11; U; Linux 2.4.0-4GB i686) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: package body functionality References: <9eoeiv$h8$1@eol.dd.chalmers.se> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Sat, 26 May 2001 19:16:07 GMT NNTP-Posting-Host: 193.217.202.196 X-Complaints-To: abuse@tele2.no X-Trace: juliett.dax.net 990904567 193.217.202.196 (Sat, 26 May 2001 21:16:07 MET DST) NNTP-Posting-Date: Sat, 26 May 2001 21:16:07 MET DST Xref: archiver1.google.com comp.lang.ada:7808 Date: 2001-05-26T19:16:07+00:00 List-Id: Staffan Dittmer wrote: > > the question might be a bit obscure but > considering the two package bodies below > > package body A is > variable: some_type:=call_some_function_outside_A; > end A; > > package body B is > variable: some_type; > begin > variable:=call_some_function_outside_B; > end B; > > I know that in B the variable will be assigned > every time a program using the package is run, > but is this also true for A, or will the variable in > this case only be assigned at compile time ? > > saturdays usually makes me confused... The function of the compiler is to convert (in this case) package body A into object code, not to execute the code in some other package (which, conceivably, might not even be compiled yet). -- -- Aron NB: To reply by e-mail, remove "spam-block." from my address. - - - - - - - - - - - "Nobody suffers the pain of birth or the anguish of loving a child in order for presidents to make wars, for governments to feed on the substance of their people, for insurance companies to cheat the young and rob the old." -- Lewis Lapham