From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=BAYES_00,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,81cf52699486abe7 X-Google-Attributes: gid103376,public From: dvdeug@x8b4e53cd. (David Starner) Subject: Re: Ada95 Strengths/Weaknesses. Date: 1999/09/27 Message-ID: <7smp30$9aa1@news.cis.okstate.edu>#1/1 X-Deja-AN: 529751757 References: <37EED7B8.245C0054@yukyonline.co.yuky> Organization: Oklahoma State University User-Agent: slrn/0.9.5.7 (UNIX) Reply-To: dstarner98@aasaa.ofe.org Newsgroups: comp.lang.ada Date: 1999-09-27T00:00:00+00:00 List-Id: In article <37EED7B8.245C0054@yukyonline.co.yuky>, the middleman wrote: >I've been learning Ada95 for a year now. And although I don't have much >experience of other languages I'd certainly say it was my favourite. >In discussions with friends the abilities of Ada95 have cropped up. I >was wondering if anyone could possibly point out the weaknesses and the >strengths that Ada95 has when compared to other languages such as C so >that I can finally set the record straight. Needless to say, it's very arguable. Here's my comparison vs. C & C++. Advantages vs. C++ * Better modularity support * Not locked into class=type pardigm * Built in tasking support * Strong typing for real * Large choice and fine control over types. (C & C++ offer at best a clumsy mechanism to chose one of the standard types.) * The libraries were written with module, exception and template support in mind (as opposed to C++ where many libraries were written before standard implementations of those were common, or for compilers that don't support them.) * Almost all Ada compilers are standard compliant (whereas few C++ compilers are totally standard compliant, and many lack major features (namespaces, templates). (Note that most C compilers _are_ ISO C compliant, one of the few advantages of C over C++). * Elegance. Ada is designed by a small team with a strong leader, and was updated from 83 to 95 by another small team with a strong leader. OTOH, C & C++ were grown languages, with gangly and arbitrary cruft everywhere, with C++ especially being designed by commitee. Additional Advantages vs. C * Any real modularity support * Object orientation, and the other aminaties of a modern language (exceptions, templates, etc) * Some saftey net against bugs (C compilers by default will let extremely questionable & machine depended code by.) Disadvatages vs. C++ * Type safety makes it harder for some stuff to get done - i.e. it's impossible to make a type look exactly like a number in Ada, but trivial in C++. * C++ includes several somewhat experimental features (template specilization, multiple inheritance) that Ada designers considered too experimental or specialized to add. Disadvantages vs. C & C++ * Large base of installed libraries. If you can find a Ada library that does what you need to do (not unlikely, but not as likely as for C or C++ - and it's probably a wrapper around a C library), it probably won't come precompiled and set up for your system, and it probably won't be installed on your user's system. * C compilers have a standardized interface. OTOH, you can distinuigsh Ada compilers by the required file names, and the interface is more variant. * C & C++ compilers will usually produce smaller and faster code, albeit usually less than an order of magnitude. David Starner - dstarner98@aasaa.ofe.org