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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,23cf9f1e93744eed X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-07-31 13:39:42 PST Path: archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-01!sn-post-02!sn-post-01!supernews.com!corp.supernews.com!not-for-mail From: "Randy Brukardt" Newsgroups: comp.lang.ada Subject: Re: Need advice re package organization. Date: Thu, 31 Jul 2003 15:41:21 -0500 Organization: Posted via Supernews, http://www.supernews.com Message-ID: References: <3F228F3B.9020203@attbi.com> <3F22F9E9.3040307@attbi.com> <5jn9ivoetll1fu2avn9hmjj6aaa7q7pmjn@4ax.com> X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4807.1700 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300 X-Complaints-To: abuse@supernews.com Xref: archiver1.google.com comp.lang.ada:41105 Date: 2003-07-31T15:41:21-05:00 List-Id: "Warren W. Gay VE3WWG" wrote in message news:AVbWa.1379$qN3.184689@news20.bellglobal.com... > > But if you do not want to see private things, then the package should > > not be a child. > > You are missing the point. If the package is not a child package, > then this new package loses all access to the other private > types declared in the private section. Sometimes you need to have > things both ways. That sounds like a very muddled design. Previously you said: > Irregardless, there is _NO_ way whatsoever to identify > Ada95 OO members/primitives as "protected" (ie. accessable > by derived code, but not to the end clients of the object). Which is false: The derived code goes in children (if they need the visibility), the end clients do not. If your end clients are in children, you've got design problems. What you're asking for is a fine-grained visibility control that does not exist anywhere in Ada. For instance, when you say "with", you get the whole package; there is no option to just get part of it. When you say "use", you get the whole package; there is no option to just get individual items. Some have claimed this is a fault, but in any case you'd have a very different language if you had those sorts of capabilities. One of the advantages of the current scheme is that it works very well for programming-in-the-large: a change to a distant unit can only change units in which it is directly referenced. We've found in working on "limited with" that this property is a lot harder to maintain if you have views of the same entity with different properties that can clash (if you have a diamond-shaped with pattern). This is a property that we should not be willing to give up for Ada. Anyway, I think you will have to make a complete proposal so we can tear it to shreds. :-) Claiming that there is some lack of visibility control without showing how that control could be defined and would be used in practice is not very compelling. Randy.