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=0.2 required=5.0 tests=BAYES_00,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,faded6ef595fd040,start X-Google-Attributes: gid103376,public From: ehsjony@ehs.ericsson.se (Jonas Nygren) Subject: Visibility of private parts Date: 1996/02/21 Message-ID: <4gf81d$p4b@erinews.ericsson.se>#1/1 X-Deja-AN: 140381829 distribution: world organization: Ericsson followup-to: comp.lang.ada reply-to: ehsjony@ehs.ericsson.se newsgroups: comp.lang.ada Date: 1996-02-21T00:00:00+00:00 List-Id: I believed that your private parts were hidden in Ada. Though, the function Bs.Something manages to call As.As_Private_Parts though it is a private type with a private procedure in the short example below. package As is type A is private; private type A is tagged null record; procedure As_Private_Parts (An_A : in out A); end As; with As; package Bs is type B is new As.A; procedure Something (A_B : in out B); end Bs; package body Bs is procedure Something (A_B : in out B) is begin As_Private_Parts(A_B); end Something; end Bs; Compiling bs.adb does not report any error - how can that be? Should B be allowed to see A's private parts? Is it a feature or a bug? /jonas