comp.lang.ada
 help / color / mirror / Atom feed
From: "Randy Brukardt" <randy@rrsoftware.com>
Subject: Re: Running a preprocessor from GPS?
Date: Wed, 29 Jul 2015 15:32:13 -0500
Date: 2015-07-29T15:32:13-05:00	[thread overview]
Message-ID: <mpbd8f$re$1@loke.gir.dk> (raw)
In-Reply-To: 014427b1-ff7a-4a69-82e6-0330af77ed96@googlegroups.com

"EGarrulo" <egarrulo@gmail.com> wrote in message 
news:014427b1-ff7a-4a69-82e6-0330af77ed96@googlegroups.com...
> On Tuesday, July 28, 2015 at 11:12:54 PM UTC+2, Randy Brukardt wrote:
>> "EGarrulo" wrote in message
>> >boilerplate code, and this is one such case.  Let's add the lack of a
>> >facility like "printf",
>>
>> Not strongly typed.
>
> What do you mean?  Common Lisp has FORMAT and it is as strongly typed as 
> they can be.

In Ada terms, typing is something done at compile-time. Ada does not have 
runtime typing (one could imagine tag checks to be runtime typing, but 
that's a check in Ada, not related to typing).

>> >along with a generic type system that can't perform basic type 
>> >inference,
>>
>> Would have to weaken the type system.
>
> Do you mean that the compiler is not able to infer the type referenced by 
> the access type in
> Ada.Unchecked_Deallocation` because that would weaken the type system?

That's not type inference by my understanding of the term. That's just a 
lack of default parameters for generic types (something that I proposed back 
in the Ada 2005, but died mainly because of a lack of appropriate syntax). 
Nothing would be inferred, any more than the number of lines output by 
New_Line is inferred.

Anyway, I can't recall any time in my entire history of Ada (goes back to 
1979) where anyone voiced the opinion that the redundancy in 
Unchecked_Deallocation is a real problem. You're at least 35 years too late 
with that opinion, as Ada.Unchecked_Deallocation goes back to Ada 80 and 
probably before that. There's no chance in heck that it would be changed 
now.

And on the list of annoyances in Ada, this is *waaayyyy* down the list. #1 
for most people is the visibility of operators. Another thing that it is way 
too late to fix (and lots of effort has been expended in trying to find a 
compatible fix).

>> > and I am beginning to understand why engineers opposed the adoption of 
>> > Ada
>> > by the US Department of Defense.
>>
>> Ada is not for people that want to write quick sloppy code (and then 
>> debug
>> it for months).
>
> Wanting to write sloppy code and wanting to write only what is necessary 
> are
> two different attitudes, don't you agree?

What *you* think is unnecessary might be very valuable in someone else's 
context. And they'd view it as "sloppy".

>> Besides, the C++ generics that you are implicitly referring
>> to didn't exist until long after Ada was designed. And they do things 
>> which
>> would destroy the Ada contract model of generics (in C++, generics are
>> glorified macros).
>
> Ada generics are fine -- I see no difference in expressiveness versus C++, 
> really -- but
> the standard library doesn't seem to make the most of them.
>
> Generics *are* glorified macros anyway, in a sense.

This is an especial sore point with me!

Formally in the Ada RM they are, which causes all manner of nonsense effects 
which then get erased by special rules. Stupid.

For Janus/Ada at least, there is nothing macro-like about them: the code 
(including the elaboration code for the specification) is fully shared, and 
it's the processed declarations that are duplicated for an instantiation, 
the source code is not involved in any way.

The language should have been defined describing the entities as being 
duplicated, not the source, since that's what happens anyway (binding 
happens when the generic is compiled, so in no sense are you duplicating 
identifiers).

C++, OTOH, is almost purely a syntax duplication; binding occurs in the 
instance, not in the original generic declaration. So the effect is very 
different, especially in terms of debuggability (one can reason about Ada 
generics because the properties of everything other than the generic formals 
are the same for all instances, and the properties of the formals are quite 
constrained; that really doesn't work in C++).

                                  Randy.





  parent reply	other threads:[~2015-07-29 20:32 UTC|newest]

Thread overview: 175+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-27 14:28 Running a preprocessor from GPS? EGarrulo
2015-07-27 16:47 ` David Botton
2015-07-27 17:17   ` EGarrulo
2015-07-27 20:26 ` Randy Brukardt
2015-07-27 21:14   ` Jeffrey R. Carter
2015-07-27 22:23     ` EGarrulo
2015-07-28  7:23       ` Simon Wright
2015-07-28 11:36   ` EGarrulo
2015-07-28 21:12     ` Randy Brukardt
2015-07-28 22:11       ` EGarrulo
2015-07-28 22:41         ` EGarrulo
2015-07-29  9:52           ` G.B.
2015-07-29 20:32         ` Randy Brukardt [this message]
2015-07-29 22:32           ` EGarrulo
2015-07-29 23:51             ` Jeffrey R. Carter
2015-07-30  0:10               ` EGarrulo
2015-07-30  6:01                 ` Niklas Holsti
2015-07-30  7:33                   ` Björn Lundin
2015-07-30  8:03                     ` EGarrulo
2015-07-30  8:08                       ` Jacob Sparre Andersen
2015-07-30  8:37                         ` EGarrulo
2015-07-30  8:49                           ` Georg Bauhaus
2015-07-30 12:15                             ` EGarrulo
2015-07-30 14:11                               ` G.B.
2015-07-30 19:29                           ` Jeffrey R. Carter
2015-07-30 20:53                             ` EGarrulo
2015-07-30 22:52                               ` Jeffrey R. Carter
2015-07-31  7:29                               ` Georg Bauhaus
2015-07-31  7:53                               ` gautier_niouzes
2015-07-31  8:26                               ` Simon Wright
2015-07-31  9:13                                 ` Dmitry A. Kazakov
2015-07-31  9:31                                   ` EGarrulo
2015-07-31 11:01                                     ` Dmitry A. Kazakov
2015-07-31 13:50                                       ` EGarrulo
2015-07-31 16:29                                         ` Dmitry A. Kazakov
2015-07-31 11:26                               ` Brian Drummond
2015-07-31 12:12                                 ` EGarrulo
2015-07-31 12:15                                 ` EGarrulo
2015-07-31 17:54                                 ` Jeffrey R. Carter
2015-07-31 18:20                                   ` EGarrulo
2015-07-31 18:51                                     ` Jeffrey R. Carter
2015-08-01  7:20                                     ` Simon Wright
2015-08-01  8:06                                       ` EGarrulo
2015-08-01  8:33                                         ` Simon Wright
2015-08-01 10:47                                           ` EGarrulo
2015-08-01 11:27                                             ` Simon Wright
2015-08-01 11:44                                             ` Niklas Holsti
2015-08-01 12:19                                               ` EGarrulo
2015-08-01 17:49                                                 ` Jeffrey R. Carter
2015-08-01 18:15                                                   ` Paul Rubin
2015-08-01 18:59                                                     ` Jeffrey R. Carter
2015-08-01 20:30                                                     ` Georg Bauhaus
2015-08-01 20:44                                                   ` EGarrulo
2015-08-01 22:44                                                     ` Jeffrey R. Carter
2015-08-01 23:39                                                       ` EGarrulo
2015-08-02  0:02                                                         ` Jeffrey R. Carter
2015-08-02  0:18                                                           ` EGarrulo
2015-08-02  0:30                                                           ` EGarrulo
2015-08-02  6:05                                                             ` Jeffrey R. Carter
2015-08-02  8:29                                                               ` EGarrulo
2015-08-02 19:21                                                                 ` Jeffrey R. Carter
2015-08-02 21:37                                                                   ` EGarrulo
2015-08-03  2:35                                                                     ` Jeffrey R. Carter
2015-08-02  2:53                                                       ` Paul Rubin
2015-08-02  6:07                                                         ` Jeffrey R. Carter
2015-08-02  8:36                                                         ` EGarrulo
2015-08-01 16:53                                         ` Jeffrey R. Carter
2015-08-01 17:00                                       ` Jeffrey R. Carter
2015-08-01  7:48                                     ` Dmitry A. Kazakov
2015-07-30  8:23                       ` Georg Bauhaus
2015-07-30  8:45                         ` EGarrulo
2015-07-30  9:19                           ` Dmitry A. Kazakov
2015-07-30 11:22                           ` Niklas Holsti
2015-07-30 13:00                             ` EGarrulo
2015-07-30 13:30                               ` Dmitry A. Kazakov
2015-07-30 13:51                                 ` EGarrulo
2015-07-30 14:13                                   ` Dmitry A. Kazakov
2015-07-30 14:46                                     ` Simon Wright
2015-07-30 14:31                           ` G.B.
2015-07-30 18:46                           ` Randy Brukardt
2015-07-30  9:18                         ` EGarrulo
2015-07-30 18:55                           ` Randy Brukardt
2015-07-30 19:32                             ` EGarrulo
2015-07-31  0:10                               ` Randy Brukardt
2015-07-30 11:35                         ` Brian Drummond
2015-07-30 13:30                           ` EGarrulo
2015-07-31 11:07                             ` Brian Drummond
2015-07-30  8:28                       ` Pascal Obry
2015-07-30 12:00                         ` EGarrulo
2015-07-30 10:01                       ` Björn Lundin
2015-07-30 10:59                         ` Pascal Obry
2015-07-30 11:21                       ` gautier_niouzes
2015-07-30 18:35                   ` Randy Brukardt
2015-07-31 15:21                     ` Stefan.Lucks
2015-07-31 17:28                       ` Pascal Obry
2015-08-01 11:38                       ` Björn Lundin
2015-08-01 20:07                         ` Stefan.Lucks
2015-08-03 23:26                       ` Randy Brukardt
2015-07-30  6:08             ` Dmitry A. Kazakov
2015-07-30  6:37             ` Georg Bauhaus
2015-07-30  8:27             ` Pascal Obry
2015-07-30  9:22               ` Dmitry A. Kazakov
2015-07-30 11:51               ` EGarrulo
2015-07-30 12:23                 ` Dmitry A. Kazakov
2015-07-30 13:55                   ` Niklas Holsti
2015-08-30  7:03                     ` David Thompson
2015-07-30 14:07                   ` EGarrulo
2015-07-30 18:12                 ` Jeffrey R. Carter
2015-07-30 18:51                   ` EGarrulo
2015-07-30 19:27                     ` Jeffrey R. Carter
2015-07-30 19:54                       ` EGarrulo
2015-07-30 22:53                         ` Jeffrey R. Carter
2015-07-30 23:58                     ` Randy Brukardt
2015-07-30 11:54               ` EGarrulo
2015-07-30 12:42                 ` Pascal Obry
2015-07-30 13:21                   ` EGarrulo
2015-07-30 13:38                     ` Dmitry A. Kazakov
2015-07-30 13:55                       ` EGarrulo
2015-07-30 15:23             ` Niklas Holsti
2015-07-30 19:32             ` Randy Brukardt
2015-07-30 20:10               ` EGarrulo
2015-07-31  0:23                 ` Randy Brukardt
2015-07-31  6:29                   ` Dmitry A. Kazakov
2015-08-02 10:08                   ` EGarrulo
2015-08-02 12:15                     ` EGarrulo
2015-07-29 23:45           ` EGarrulo
2015-07-30  0:25             ` Jeffrey R. Carter
2015-07-30  8:12               ` EGarrulo
2015-07-30 18:01                 ` Jeffrey R. Carter
2015-07-29  6:46       ` Simon Wright
2015-07-29  7:17         ` Dmitry A. Kazakov
2015-07-29 19:57         ` Randy Brukardt
2015-07-29 20:09           ` Jeffrey R. Carter
2015-07-30 18:16             ` Randy Brukardt
2015-07-29 20:38           ` Simon Wright
2015-07-30  7:50             ` Jacob Sparre Andersen
2015-07-30 14:48               ` G.B.
2015-07-30 15:58                 ` Simon Wright
2015-07-30 15:13             ` EGarrulo
2015-07-30 15:21               ` EGarrulo
2015-07-30 15:29               ` G.B.
2015-07-30 16:02               ` Simon Wright
2015-07-30 16:15               ` Simon Wright
2015-07-30 16:29                 ` EGarrulo
2015-07-30 17:31                   ` Simon Wright
2015-07-28 10:28 ` Brian Drummond
2015-07-28 11:39   ` EGarrulo
2015-07-29 10:02     ` Brian Drummond
2015-07-29 10:29     ` Brian Drummond
2015-07-29 12:00       ` EGarrulo
2015-07-29 19:23         ` gautier_niouzes
2015-07-28 11:43 ` Björn Lundin
2015-07-28 11:51   ` Dmitry A. Kazakov
2015-07-28 12:06     ` EGarrulo
2015-07-28 12:54       ` Dmitry A. Kazakov
2015-07-28 13:18         ` EGarrulo
2015-07-28 13:49           ` EGarrulo
2015-07-28 14:02             ` Bob Duff
2015-07-28 14:57             ` G.B.
2015-07-28 15:36           ` Dmitry A. Kazakov
2015-07-29  7:15           ` Stefan.Lucks
2015-07-29  7:52             ` EGarrulo
2015-07-29 17:30               ` Stefan.Lucks
2015-07-29 18:49                 ` Jeffrey R. Carter
2015-07-29 20:40                   ` Randy Brukardt
2015-07-30  7:40                     ` gautier_niouzes
2015-07-30 19:22                       ` Randy Brukardt
2015-07-28 13:06       ` G.B.
2015-07-28 13:19         ` EGarrulo
2015-07-28 20:55           ` Randy Brukardt
2015-07-28 22:31             ` EGarrulo
2015-07-29 20:09               ` Randy Brukardt
2015-07-29 22:40                 ` EGarrulo
2015-07-28 12:07     ` Björn Lundin
2015-07-31 19:44 ` Per Sandberg
replies disabled

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