comp.lang.ada
 help / color / mirror / Atom feed
From: Andy S <andy@nospam.com.tj>
Subject: Re: packet type ?
Date: 2000/01/20
Date: 2000-01-20T12:39:42+00:00	[thread overview]
Message-ID: <38871060.37CA@nospam.com.tj> (raw)
In-Reply-To: Pine.BSF.4.21.0001190930400.18715-100000@shell5.ba.best.com

Brian Rogoff wrote:
> Ada 95 also allows you to create a stack signature
> 
> generic
>     type Item_Type is private;
>     type Stack_Type is private;
>     with procedure Push(Stack : in out Stack_Type; Item : in Item_Type);
>     with procedure Pop(Stack : in out Stack_Type; Item : out Item_Type);
>     ...
> package Stack_Sig is begin end;
> 
> and write code which only depends on an instantiation having that profile,
> so that your stack code and many others can supply the stack ADT for the
> code. This is a very nice feature of Ada 95 which is not described in many
> Ada books; Barnes and Ben-Ari are exceptional here.
> 
Are you sure? My GNAT compiler barffed at this one !

___________________________________________

   Andy Starritt
___________________________________________




  reply	other threads:[~2000-01-20  0:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-01-14  0:00 packet type ? Alfred Hilscher
2000-01-14  0:00 ` Ted Dennison
2000-01-18  0:00   ` Alfred Hilscher
2000-01-18  0:00     ` Brian Rogoff
2000-01-18  0:00     ` Ted Dennison
2000-01-19  0:00     ` Anders Gidenstam
2000-01-19  0:00       ` Brian Rogoff
2000-01-20  0:00         ` Andy S [this message]
2000-01-20  0:00           ` Brian Rogoff
2000-01-20  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