comp.lang.ada
 help / color / mirror / Atom feed
From: "SteveD" <nospam_steved94@attbi.com>
Subject: Re: A little help on Generics.
Date: Tue, 25 Jun 2002 02:52:31 GMT
Date: 2002-06-25T02:52:31+00:00	[thread overview]
Message-ID: <PVQR8.142019$R61.52806@rwcrnsc52.ops.asp.att.net> (raw)
In-Reply-To: iOyR8.304072$cQ3.16530@sccrnsc01

To create an instance of the package:

> generic
>    Max : Positive;
>    type Item is private;
> package genstack is

Use:
  package Int_Stack is new genstack(Max => 500, Item => Integer);

Not:
  type Int_Stack is new genstack(Max => 500, Item => Integer);

Then you can use Int_Stack just a if it were a non-generic package.

You're close.  You are very very close.

SteveD






  parent reply	other threads:[~2002-06-25  2:52 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-24  6:15 A little help on Generics Caffeine Junky
2002-06-24  7:34 ` Dale Stanbrough
2002-06-24 10:49 ` Jeffrey Creem
2002-06-24 18:50   ` Caffeine Junky
2002-06-24 20:21     ` Jeffrey Creem
2002-06-24 22:29       ` Caffeine Junky
2002-06-25  2:52 ` SteveD [this message]
2002-06-25  7:25   ` Caffeine Junky
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox