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.3 required=5.0 tests=BAYES_00,INVALID_MSGID, MSGID_RANDY autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,84b1828b2b26fc4f,start X-Google-Attributes: gid103376,public From: dmitry6243@my-deja.com Subject: Common ancestor (visibility rules) Date: 2000/03/28 Message-ID: <8bprin$a37$1@nnrp1.deja.com>#1/1 X-Deja-AN: 603320254 X-Http-Proxy: 1.0 x35.deja.com:80 (Squid/1.1.22) for client 212.79.192.251 Organization: Deja.com - Before you buy. X-Article-Creation-Date: Tue Mar 28 08:47:22 2000 GMT X-MyDeja-Info: XMYDJUIDdmitry6243 Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.7 [en] (WinNT; I) Date: 2000-03-28T00:00:00+00:00 List-Id: Hello! Perhaps I've missed something, but it seems that compilation units (except for library ones) do not have common ancestor. Here is a simple example to highlight the problem: ------------------- a.ads package A is procedure Foo; end A; ------------------- b.ads package B is procedure A; end B; ------------------- b.adb package body B is procedure A is separate; end B; ------------------- b-a.adb with A; separate (B) procedure A is begin A.Foo; -- Error! end A; Now there is no way to use A.Foo in B.A, because B.A hides A. The problem could be easily solved if all compilation unit had have a common ancestor package, say "Root". Then package A could be specified as Root.A and A's Foo as Root.A.Foo. Interesting is that C++ has this feature. Regards, Dmitry Kazakov Sent via Deja.com http://www.deja.com/ Before you buy.