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.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,437103ff8a92c0df X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!news.glorb.com!news.addix.net!border2.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!feeder.news-service.com!post.news-service.com!news1.surfino.com!not-for-mail Message-Id: <8065486.gdOUxkNXWZ@linux1.krischik.com> From: Martin Krischik Subject: Re: generics and records Newsgroups: comp.lang.ada Reply-To: martin@krischik.com Date: Tue, 01 Mar 2005 12:21:27 +0100 References: <1109532840.857126.234720@z14g2000cwz.googlegroups.com> Organization: None User-Agent: KNode/0.8.0 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Complaints-To: abuse@surfino.com NNTP-Posting-Host: 83.169.175.19 (83.169.175.19) NNTP-Posting-Date: Tue, 01 Mar 2005 13:00:19 +0100 X-Trace: 7e89c42245953f60c0ab603903 Xref: g2news1.google.com comp.lang.ada:8565 Date: 2005-03-01T12:21:27+01:00 List-Id: spambox@volja.net wrote: > Hello, > in the process of learning Ada, I came to the problem of generics and > records. I want to instantiate a package with a record type: > > generic > type x is private; You need a common ancestor class for this construct to work: type x is new y with private; > package ... > private > type xx is new x; > end ... Martin -- mailto://krischik@users.sourceforge.net Ada programming at: http://ada.krischik.com