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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,1ed4b5bd91d02f0b X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!news1.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nac.net!newspeer.monmouth.com!peer.news.zetnet.net!peer-uk.news.demon.net!kibo.news.demon.net!mutlu.news.demon.net!news.demon.co.uk!demon!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: using an Ada.Container as a private type Date: Fri, 04 Apr 2008 20:37:38 +0100 Organization: Pushface Message-ID: References: <42c84166-c7e4-42e0-b1bf-2104d3bb0cda@e10g2000prf.googlegroups.com> <5c9b6d27-d54a-43ae-aba8-8ef4b522fbc5@e10g2000prf.googlegroups.com> NNTP-Posting-Host: pogner.demon.co.uk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: news.demon.co.uk 1207337858 8566 62.49.19.209 (4 Apr 2008 19:37:38 GMT) X-Complaints-To: abuse@demon.net NNTP-Posting-Date: Fri, 4 Apr 2008 19:37:38 +0000 (UTC) Cancel-Lock: sha1:M6inagSJwu52sB1CWAUzznPDjw8= User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (darwin) Xref: g2news1.google.com comp.lang.ada:20819 X-Original-Bytes: 1755 Date: 2008-04-04T20:37:38+01:00 List-Id: Robert A Duff writes: > Graham writes: > >> Good question. The intention was not to derive from Map at all: I >> simply wanted to keep the fact that it was implemented as a Map >> private. Is there a better way of doing that,... > > You could say: > > type Payment_Stream is > record > M : Payment_Stream_Package.Map; > end record; > > which might be better, depending on what you want. You could also, for example, include a mutex in the record for locking in the presence of concurrency.