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=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,c05e0fdf8994cb5d,start X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-09-24 13:38:12 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news.tele.dk!small.news.tele.dk!213.56.195.71!fr.usenet-edu.net!usenet-edu.net!enst!enst.fr!not-for-mail From: ANH_VO@udlp.com Newsgroups: comp.lang.ada Subject: Extended Type With Discriminant Date: Mon, 24 Sep 2001 13:10:10 -0500 Organization: ENST, France Sender: comp.lang.ada-admin@ada.eu.org Message-ID: Reply-To: comp.lang.ada@ada.eu.org NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Trace: avanie.enst.fr 1001363890 81790 137.194.161.2 (24 Sep 2001 20:38:10 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Mon, 24 Sep 2001 20:38:10 +0000 (UTC) To: comp.lang.ada@ada.eu.org Return-Path: Content-Description: cc:Mail note part Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0.4 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: comp.lang.ada mail<->news gateway List-Unsubscribe: , List-Archive: Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: archiver1.google.com comp.lang.ada:13302 Date: 2001-09-24T13:10:10-05:00 GNAT 3.13p on Windows 95 threw an error message of "base-standard_io-discrete_in.ads:20:40: full view must inherit discriminants of the parent type used in the private extension" for the codes below. I believe the codes are fine. In fact, the compiled fine under ObjectAda and APEX. However, I could be wrong since I have been before. Therefore, I would like to see additional confirmation before reporting it. with Ada.Finalization; package Base is package Attribute is Invalid_Attribute : exception; Invalid_Object : exception; type Object is abstract tagged null record; type Class_Object_Access is access all Object'Class; type Constant_Class_Object_Access is access constant Object'Class; procedure Set_Attribute (This : in out Object; Attribute_Name : in String; Value : in String) is abstract; procedure Validate (This : in Object) is abstract; end Attribute; type Object (Attributes : Attribute.Constant_Class_Object_Access) is abstract new Ada.Finalization.Limited_Controlled with null record; type Object_Access is access all Object; type Class_Object_Access is access all Object'Class; private Package_Id : constant String := "Base"; end Base; generic type Base_Type (<>) is abstract new Base.Object with private; package Base.Attach_To_Service is type Object is abstract new Base_Type with record Event : String (1 .. 3); end record; procedure Initialize (This : in out Object); procedure Finalize (This : in out Object); package Attach_Wait is type Object is abstract new Attach_To_Service.Object with record Consumer_Handle : Integer; end record; -- operation declaration section end Attach_Wait; end Base.Attach_To_Service; with Base.Attach_To_Service; package Base.Standard_Io.Discrete_In is package Event_Mix_In is new Base.Attach_To_Service (Base.Standard_Io.Object); type Object is abstract new Event_Mix_In.Attach_Wait.Object with private; type Object_Access is access all Object; type Class_Object_Access is access all Object'Class; private package Extended is type Object is abstract new Event_Mix_In.Attach_Wait.Object with null record; -- operation declaration section end Extended; type Object is abstract new Extended.Object with null record; end Base.Standard_Io.Discrete_In;