comp.lang.ada
 help / color / mirror / Atom feed
From: daveh@cbmvax.UUCP (Dave Haynie)
Subject: Re: "C" vrs ADA
Date: Wed, 26-Aug-87 14:30:58 EDT	[thread overview]
Date: Wed Aug 26 14:30:58 1987
Message-ID: <2260@cbmvax.UUCP> (raw)
In-Reply-To: 36@sarin.UUCP

in article <36@sarin.UUCP>, eric@sarin.UUCP (Eric Beser sys admin) says:
> Summary: not true ... not true
> Xref: cbmvax comp.lang.ada:573 comp.lang.c:3880 sci.space:2640 sci.space.shuttle:278
> 
>    Working in an industrial environment, and having used Ada, I do not see
> how the "size" of a compiler matters in producing code that is efficient,
> that is easily maintainable, and documentable. 

That's not what I said, and hopefully not what I implied.  Once you learn
the language, the size of the compiler has nothing at all to do with producing
code that's easily maintainable and documentable, for certain.   It may have
something to do with the efficiency of the code, but that's more an 
implementation detail.  They are certainly building compilers that code as
efficiently as C for Ada these days.

However, the size of a compiler does have everything to do with the correctness
of the object code that the compiler will produce.  Especially once you start
adding in global optimizers and other items designed to produce much more
efficient code.  A larger compiler just has to be more complex than a smaller
compiler, and thus it is more prone to containing errors that were not
caught during validation.  Because a complete validation test is very hard to
design.  Not impossible, but difficult.  And you may not learn of the bug,
especially in the case of languages used in Space and other hostile environs,
until you hit a special case 100 million miles from Earth.

> If you are used to C, you
> may have trouble adjusting to the strong typing of the language. Ada is
> a verbose language (if rich can be stated in any other words). But it is that
> richness that makes the language so useful.

What I mean by verbose is that it's wordy.  Perhaps not as bad as M2 or Pascal,
but it's wordy.  Statement vs. Operation oriented.  So while my C function 
appears as a whole in my Emacs window, my Ada function fills three screens.
That's completely independent of richness.  And as richness goes, C does
pretty well as far as operator richness that Ada doesn't seem to consider
necessary.  All I'm saying is that that's what a C programmer will object
to (I know this, I programmed in Pascal for 4 years).  I use a C with ANSI
prototyping; gives me the same level of type checking as I'd get in Ada or 
Pascal, same level of data abstraction available in Pascal.  But I'm not
forced into it.

>> As for where it's used, mainly DOD I'd guess.  It certainly isn't used much,
>> if any, in commercial or industrial sectors.  C's the language for most of
>> these, though your Fortran experience could come in handy in some heavy
>> duty scientific fields (most machines have Fortran compilers that code better
>> than existing C compilers, but since there's more work being done on C, I
>> wouldn't be surprised if this is changing).  

Forgot the Business sector's COBOL, and of course the prevalence of BASIC in
the homes.  I wonder who programs the most in what (ignoring whether they
do it for fun or profit).  I bet BASICs the closet to COBOL.  Tells you that
acceptance of a language rarely has anything to do with the language's
overall quality; it's usually chosen for one or two reasons that don't always
apply to the other things its used for.

>   I get irked when I hear this. This may have been true a year ago, but no
> longer. Many customers (non DOD or NATO) are requesting Ada because of the
> software engineering that it dictates. 

And many organizations forced to use Ada are getting around this by using
C to Ada translators.  Which I'm sure we both agree is a dumb idea, but
they're still being used.  And my point here is that I can engineer my software
properly in C, even though it makes no attempt to force me to do so.  And I
can engineer my software poorly in Ada, even if it tries to make me do it
correctly.  

>   I am part of a large Ada project that is building a tool for use by our
> engineers (industrial, commercial, as well as DOD contracts). After coding
> this tool, we determined that some inefficiencies dictated a design change.
> This design change proliferated itself through the entire system. The coding
> for this change took about a man-month, but the debug and reintegration
> phase took only two days. The system ran as before, must more efficient
> due to the design change. Had the code been written in C, this would not
> have happened. Many of the errors that were interjected by the engineers
> were due to spelling, wrong variable selection, or unhandled boundary
> conditions. These errors would not have come out during C compilation.

Now who's talking about things that are no longer true.  The Lattice Compiler
I have on my Amiga, while by no means an up-to-date release, will very good
type checking and would have caught most of these problems.  Unfortunately
PCC doesn't do this yet.

> Eric Beser
> EBESER@ADA20   - arpa
> {mimsy}!aplcen!cp1!sarin!eric - usenet
-- 
Dave Haynie     Commodore-Amiga    Usenet: {ihnp4|caip|rutgers}!cbmvax!daveh
"The A2000 Guy"                    PLINK : D-DAVE H             BIX   : hazy
     "God, I wish I was sailing again"	-Jimmy Buffett, Dave Haynie

  parent reply	other threads:[~1987-08-26 18:30 UTC|newest]

Thread overview: 59+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1987-08-17 21:36 "C" vrs ADA Glen Harman
1987-08-18 14:49 ` spf
1987-08-19 17:03   ` "C" AND Ada Eugene Miya N.
1987-08-20  1:52     ` Richard Harter
1987-08-20 17:29       ` "C" AND Ada (epigram) David Palmer
1987-08-21  9:09       ` "C" AND Ada Kent Paul Dolan
1987-08-19 20:45   ` "C" vrs ADA ark
1987-08-20 20:10     ` Stephen 2. Williams
1987-08-21  0:19     ` Jef Poskanzer
1987-08-21  9:15     ` Webber
1987-08-21  1:04   ` R.A. Agnew
1987-08-21 15:27     ` spf
1987-08-23  0:35     ` Henry Spencer
1987-08-23 18:07       ` wyatt
1987-08-25 17:55         ` John Unekis
1987-08-25 18:57       ` David C. Albrecht
1987-08-27 16:32         ` Henry Spencer
1987-08-28 16:31           ` Renu Raman, Sun Microsystems
1987-08-28 15:51         ` Peter da Silva
1987-08-30  1:05           ` Rahul Dhesi
1987-08-31 13:55             ` sns
1987-09-04 16:51             ` VAX/VMS C Jim Sullivan
1987-08-18 15:17 ` "C" vrs ADA G.Gleason
1987-08-18 18:09 ` John Unekis
1987-08-21 12:07   ` Mr. Patrick J. Kelly Jr. GS-13
1987-08-21 13:00   ` steve
1987-08-21 14:04   ` Stefan M. Vorkoetter
1987-08-22 23:31     ` COBOL vs "C" vs ADA neubauer
1987-08-24 23:11       ` Dave Levenson
1987-08-25 19:18         ` FORTRAN vs COBOL vs Pascal vs C " Stephen the Greatest
1987-08-23 13:13     ` COBOL vrs Ada (was: Re: "C" vrs ADA) Kent Paul Dolan
1987-08-21 14:17   ` "C" vrs ADA M.P.Lindner
1987-08-21 15:10   ` Dave Haynie
1987-08-21 16:07   ` crowl
1987-08-22  2:44     ` hitchens
1987-08-27 18:53       ` jym
1987-08-22 14:31     ` Roy Smith
1987-08-26 16:17     ` Kurt Hoyt
1987-08-23  0:33   ` Henry Spencer
1987-08-18 18:43 ` Dave Haynie
1987-08-22 21:09   ` Eric Beser sys admin
1987-08-25 16:35     ` David Palmer
1987-08-26 14:21       ` spf
1987-08-28  0:49       ` peter
1987-09-03 20:03         ` R.A. Agnew
1987-08-26  3:38     ` Doug Gwyn 
1987-08-26 19:32       ` Charles Simmons
1987-08-26  9:25     ` Randell Jesup
1987-08-26 15:40     ` M.P.Lindner
1987-08-27 17:44       ` Jeff Bartlett
1987-08-31 17:53         ` mpl
1987-09-01 22:03           ` Barry Margolin
1987-09-02  0:32       ` eric
1987-08-26 18:30     ` Dave Haynie [this message]
1987-08-29  6:25     ` Henry Spencer
1987-09-01 19:02 ` Jacob Gore
1987-09-02 14:09 ` stt
  -- strict thread matches above, loose matches on Subject: below --
1987-08-25 20:44 blackje%sungod.tcpip
     [not found] <822@s.cc.purdue.edu>
1987-08-28 12:33 ` kelly
replies disabled

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