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,3c256edee673e6 X-Google-Attributes: gid103376,public From: Robert A Duff Subject: Re: Problem with controlled types Date: 1998/12/14 Message-ID: #1/1 X-Deja-AN: 422223437 Sender: bobduff@world.std.com (Robert A Duff) References: <753cnv$3sq$1@nnrp1.dejanews.com> Organization: The World Public Access UNIX, Brookline, MA Newsgroups: comp.lang.ada Date: 1998-12-14T00:00:00+00:00 List-Id: bourguet@my-dejanews.com writes: > package Pkg is > > type A is private; > -- operations on B > > type B is private; > > function Get_B (I: A) return B; > -- other operations on B > > private > > type A is new Ada.Finalization.Controlled with record > ... > end record; > > type B is new Ada.Finalization.Controlled with record > ... > end record; > > end pkg; > > ObjectAda complain that the Get_B function is primitive on two tagged > types, and that is not allowed. > > Gnat compile and run correctly (as A'Class contains only A and > B'Class only B, this is not strange). > > Now, which one is correct? ObjectAda. - Bob -- Change robert to bob to get my real email address. Sorry.