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=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,80435549e92d4e0c X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!news.glorb.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local01.nntp.dca.giganews.com!nntp.scarlet.biz!news.scarlet.biz.POSTED!not-for-mail NNTP-Posting-Date: Tue, 06 Sep 2005 00:07:00 -0500 From: Ludovic Brenta Newsgroups: comp.lang.ada Subject: Re: Charles container library usage examples References: <87mzmssqbq.fsf@ludovic-brenta.org> Date: Tue, 06 Sep 2005 07:08:00 +0200 Message-ID: <87psrmrdfz.fsf@ludovic-brenta.org> User-Agent: Gnus/5.110004 (No Gnus v0.4) Emacs/21.4 (gnu/linux) Cancel-Lock: sha1:pYC312nO6rQxWfCCuo8B5boOXw4= MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii NNTP-Posting-Host: 83.134.238.101 X-Trace: sv3-anu7Lao8HJhRpAX0okr3E8CpQGRSqcuooQZbWdNoJoF0CaZ74nhARPCND3gZc6qki58wAAg6NaxsTTW!6cBNFVG4MSCRhvDUptuK2kEDecqD15yNmd8N+9YIvj3nCdGS4CPzrPUe2t2LbjMFYYbrsW/HTPo= X-Complaints-To: abuse@scarlet.be X-DMCA-Complaints-To: abuse@scarlet.biz X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.32 Xref: g2news1.google.com comp.lang.ada:4461 Date: 2005-09-06T07:08:00+02:00 List-Id: David Trudgett writes: > 1. Is my INITIALIZE procedure more verbose than it needs to be? I > wanted to put the array definitions inside the call to INSERT, but > I don't think that's possible. procedure Initialize (Self : in out Board) is begin Reset(Self); Insert(Side_Corners, 2, (1, 3)); Insert(Side_Corners, 4, (1, 7)); Insert(Side_Corners, 6, (3, 9)); Insert(Side_Corners, 8, (7, 9)); end Initialize; > 2. Did I need the separate file "corner_list.ads"? I tried to put it > in "side_corners_map.ads", but the compiler didn't seem to like > that idea. Yes, you need one because Side_Corner_Maps must be instantiated at "library level". This prevents dangling references to nested types. -- Ludovic Brenta.