From: tmoran@bix.com
Subject: losing visibility
Date: Mon, 23 Oct 2000 02:32:22 GMT
Date: 2000-10-23T02:32:22+00:00 [thread overview]
Message-ID: <WqNI5.348353$i5.5348409@news1.frmt1.sfba.home.com> (raw)
Would someone please refresh my memory as to why "nucleus" should
become invisible in:
package one is
type root is tagged private;
private
type root is tagged record
nucleus : integer;
end record;
end one;
package one.two is
package three is
type child is new one.root with private;
private
type child is new one.root with record
electrons : integer;
end record;
end three;
package four is
type grandkid is new three.child with null record;
procedure initialize(x : in out grandkid);
end four;
end one.Two;
package body one.Two is
package body four is
procedure initialize(x : in out grandkid) is
begin
x.nucleus := 1; -- <<<<<<<<<<<<<< BAD nucleus not visible
end initialize;
end four;
y : four.grandkid;
begin
one.root(y).nucleus := 2; -- <<<<<<<<<<<<<< OK, nucleus visible
y.nucleus := 3; -- <<<<<<<<<<<<<< BAD, nucleus not visible
end one.Two;
with one.Two;
procedure testvis is
begin null;end testvis;
next reply other threads:[~2000-10-23 2:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-10-23 2:32 tmoran [this message]
2000-10-23 0:00 ` losing visibility Pascal Obry
2000-10-24 0:00 ` Tucker Taft
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox