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.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,15d588b58ebcebac X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!t-online.de!inka.de!rz.uni-karlsruhe.de!news.belwue.de!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail From: "Dmitry A. Kazakov" Subject: Re: Initializers Newsgroups: comp.lang.ada User-Agent: 40tude_Dialog/2.0.15.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Reply-To: mailbox@dmitry-kazakov.de Organization: cbb software GmbH References: <1166580131.054327.67090@80g2000cwy.googlegroups.com> Date: Wed, 20 Dec 2006 11:35:13 +0100 Message-ID: NNTP-Posting-Date: 20 Dec 2006 11:35:06 CET NNTP-Posting-Host: 559d25c7.newsspool4.arcor-online.net X-Trace: DXC=Z[KA9X\`0FZI?44J>Z[:RQ4IUKbPFX_PDNcfSJ;bb[UIRnRBaCd On 19 Dec 2006 18:02:11 -0800, markww wrote: > I'm trying to compare C++ to Ada. I'm looking specifically at Ada's > lack of 'initializers'. I am guessing that this means there is no > 'constructor' to Ada packages maybe? If that's the case - where do you > initialize anything that needs setup when it comes into existence? They exist, the things they do Ada reference manual calls "package elaboration." You can attach your code to elaboration in many ways. Begin in the package body was already mentioned. Then of course all initialized objects declared in the package are initialized during elaboration. For example, constants take values, tasks start, controlled objects get their Initialize called etc. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de