comp.lang.ada
 help / color / mirror / Atom feed
From: "Randy Brukardt" <randy@rrsoftware.com>
Subject: Re: Callback in Ada
Date: Tue, 4 Jan 2011 14:21:30 -0600
Date: 2011-01-04T14:21:30-06:00	[thread overview]
Message-ID: <ifvvgd$h28$1@munin.nbi.dk> (raw)
In-Reply-To: wccmxngzc0x.fsf@shell01.TheWorld.com

"Robert A Duff" <bobduff@shell01.TheWorld.com> wrote in message 
news:wccmxngzc0x.fsf@shell01.TheWorld.com...
...
> Others argued that we don't want to give people the ability to
> completely dispense with Ada's separation of spec and body.
> Also, the expression function syntax is nice for short
> "one liners", where the extra verbiage of "begin" and
> "end Blah;" is just noise.

To expand on this a bit.

Ada always has had the ability to put arbitrary expressions into package 
specifications (default expressions, initializing expressions, etc.). This 
new capability just provides a way to give those expressions a convinient 
name.

OTOH, Ada only has one way to put a body into a package specification (via a 
generic instantiation - and it is rarely used for this purpose). Adding more 
ways to put a body into a package specification seems to change the model of 
the language, and might also pose new implementation difficulties 
(implementations might somehow depend on the absence of bodies). Indeed, it 
is likely that there are language rules which depend on this absence (I 
distinctly remember a freezing rule that only works because there cannot be 
a procedure call in a package specification, although I wasn't able to turn 
up a reference to that). So allowing full bodies in package specifications 
is a lot more risky than just allowing expressions.

                                Randy.





  reply	other threads:[~2011-01-04 20:21 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-27  9:47 Callback in Ada Georg Maubach
2010-11-27 10:11 ` Dmitry A. Kazakov
2010-11-27 10:22 ` Ludovic Brenta
2010-11-27 11:04   ` Vinzent Hoefler
2010-11-27 22:05   ` Maciej Sobczak
2010-11-27 10:26 ` Alex Mentis
2010-11-27 10:46 ` Vinzent Hoefler
2010-11-27 11:32 ` Georg Bauhaus
2010-11-27 21:11   ` Jeffrey Carter
2010-11-27 21:20     ` Dmitry A. Kazakov
2010-11-28 21:35       ` Maciej Sobczak
2010-11-29  8:41         ` Dmitry A. Kazakov
2010-11-29 10:12           ` Maciej Sobczak
2010-11-29 11:04             ` Dmitry A. Kazakov
2010-11-30  1:32               ` Randy Brukardt
2010-11-30  8:38                 ` Dmitry A. Kazakov
2010-11-30  9:14                 ` AdaMagica
2010-11-30 12:37                   ` Georg Bauhaus
2010-11-30 20:28                     ` Randy Brukardt
2010-11-30 20:31                   ` Randy Brukardt
2011-01-01 16:46                 ` Yannick Duchêne (Hibou57)
2011-01-02 10:14                   ` AdaMagica
2011-01-02 14:11                     ` Robert A Duff
2011-01-02 15:15                       ` AdaMagica
2011-01-02 15:28                         ` Robert A Duff
2011-01-02 15:38                       ` Alex Mentis
2011-01-02 15:44                         ` Robert A Duff
2011-01-03 21:38                           ` Randy Brukardt
2011-01-04  0:11                             ` Robert A Duff
2011-01-04 18:33                             ` Alex Mentis
2011-01-04 19:47                               ` Robert A Duff
2011-01-04 20:21                                 ` Randy Brukardt [this message]
2011-01-04 20:15                               ` Randy Brukardt
2010-11-29 15:24     ` Callback in Ada (User Data argument) Warren
2010-11-30  1:35       ` Randy Brukardt
2010-11-30 16:51         ` Warren
replies disabled

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