comp.lang.ada
 help / color / mirror / Atom feed
Subject: Re: something I would like to see in ADA 2005
Date: Tue, 15 Apr 2003 10:10:57 +0200
Date: 2003-04-15T10:10:57+02:00	[thread overview]
Message-ID: <3e9bbec7$1@epflnews.epfl.ch> (raw)
In-Reply-To: 6a90b886.0304140639.4ee1abfb@posting.google.com

Tony Gair wrote:
>>How would tasks help?  Task types are no more generic than protected
>>types.  If you want genericity, you have to wrap it in a package.
> 
> 
> Maybe I can use a generic package, but I would like to declare a
> protected type the same way I declare a package or a task.

   You can. I suspect you are only using "single protected" declarations 
in your code... but nothing prevents you from writing:

   protected type Resource (I : in Positive) is
      ...
   end Resource;

   And then you can declare objects of type "Resource" even with a 
discriminant to customize them. Is that what you meant by genericity?

> I disagree with the statement that tasks are no more generic than
> PO's.

   I do not.

> For instance try declaring a generic protected object.

   Try declaring a generic task if you can  ;)

Rodrigo




  parent reply	other threads:[~2003-04-15  8:10 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-10 13:22 something I would like to see in ADA 2005 Tony Gair
2003-04-10 14:04 ` Hyman Rosen
2003-04-14 14:34   ` Tony Gair
2003-04-14 15:33     ` Bill Findlay
2003-04-10 14:12 ` David C. Hoos
2003-04-10 14:24   ` Peter Hermann
2003-04-11  0:10 ` Robert A Duff
2003-04-14 14:39   ` Tony Gair
2003-04-14 15:34     ` Wesley Groleau
2003-04-14 15:41     ` Bill Findlay
2003-04-15  8:10     `  [this message]
2003-04-15  8:29       ` 
2003-04-14 15:40 ` Stephen Leake
replies disabled

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