comp.lang.ada
 help / color / mirror / Atom feed
From: "J-P. Rosen" <rosen@adalog.fr>
Subject: Re: Discriminated records are not the most efficient, but ...
Date: Mon, 23 Aug 2010 08:25:59 +0200
Date: 2010-08-23T08:25:59+02:00	[thread overview]
Message-ID: <i4t49q$kpu$1@news.eternal-september.org> (raw)
In-Reply-To: <op.vhvgxm1rule2fv@garhos>

Le 23/08/2010 05:50, Yannick Duchêne (Hibou57) a écrit :
> So task or protected are compilation_unit... only when separate ? So
> what makes it not a compilation_unit when not separate ?
> 
> Unless I am missing something else, this seems strange to me.
> 
Don't be fooled by the word "unit". In Ada, you have program units and
compilation units, and they are orthogonal.
-Program unit: a logical unit that can have behaviour (i.e. statements).
-Compilation unit: something that can be given to the compiler without
being nested into something else.

For example, a package is one program unit. It is made of two parts,
spec and body, where each is a compilation unit (can be compiled
separately).

A task is a type, not a module. Therefore, it is a program unit, not a
compilation unit. However, any separate body can be compiled separately
(of course!), and is a compilation unit.

-- 
---------------------------------------------------------
           J-P. Rosen (rosen@adalog.fr)
Visit Adalog's web site at http://www.adalog.fr



  reply	other threads:[~2010-08-23  6:25 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-21 21:18 Discriminated records are not the most efficient, but Yannick Duchêne (Hibou57)
2010-08-21 21:57 ` Yannick Duchêne (Hibou57)
2010-08-22  5:39   ` Yannick Duchêne (Hibou57)
2010-08-22 20:40     ` Yannick Duchêne (Hibou57)
2010-08-22 20:47       ` Florian Weimer
2010-08-22 22:07         ` Yannick Duchêne (Hibou57)
2010-08-22 22:11           ` Yannick Duchêne (Hibou57)
2010-08-23  3:06           ` Peter C. Chapin
2010-08-23  3:50             ` Yannick Duchêne (Hibou57)
2010-08-23  6:25               ` J-P. Rosen [this message]
2010-08-23  8:09                 ` Yannick Duchêne (Hibou57)
2010-08-23  6:40               ` Niklas Holsti
2010-08-23  7:33                 ` Simon Wright
2010-08-23 11:44                   ` Martin
2010-08-23 13:16                     ` Georg Bauhaus
2010-08-23 13:32                       ` Martin
2010-08-23 17:02                       ` Yannick Duchêne (Hibou57)
2010-08-23  8:13                 ` Yannick Duchêne (Hibou57)
2010-08-23  1:52         ` Yannick Duchêne (Hibou57)
2010-08-23  5:14           ` Yannick Duchêne (Hibou57)
2010-08-23  5:43             ` Florian Weimer
2010-08-23  7:55               ` Yannick Duchêne (Hibou57)
2010-08-23  8:06                 ` Dmitry A. Kazakov
2010-08-23  8:26                   ` Yannick Duchêne (Hibou57)
2010-08-23  8:43                     ` Dmitry A. Kazakov
2010-09-04 18:49             ` Florian Weimer
replies disabled

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