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 autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,23e3ddd47450e30c X-Google-Attributes: gid103376,public From: bobduff@world.std.com (Robert A Duff) Subject: Re: Ada 95 visibility question Date: 1997/09/26 Message-ID: #1/1 X-Deja-AN: 275597539 References: <342A7989.219C@catalina-inter.net> Organization: The World Public Access UNIX, Brookline, MA Newsgroups: comp.lang.ada Date: 1997-09-26T00:00:00+00:00 List-Id: In article <342A7989.219C@catalina-inter.net>, Chris Sparks (Mr. Ada) wrote: >Wouldn't peek_a_boo be visible since the types are part of the "c" (no >pun intended) hierarchy? No. It's not unreasonable to think that ought to be the case, but the actual rules in the RM say otherwise. As I said, it's a subtle issue. You inherit from your parent, not your grandparent. You inherit stuff from your grandparent only because your parent inherited those things. And your visibility on those things depends on your visibility of your parent. In this case, you know who your grandparent is, and you know it has the Peek_A_Boo component, but you don't know *you* have that component. It's just a minor oddity caused by Ada's model of always having an imaginary (implicit) declaration for these things, which occurs (or is imagined to occur) in some well-defined place in the program. - Bob