Turamnvia said:
I 'm following various posting in "comp.lang.ada, comp.lang.c++ ,
comp.realtime, comp.software-eng" groups regarding selection of a
programming language of C, C++ or Ada for safety critical real-time
applications. The majority of expert/people recommend Ada for safety
critical real-time applications.
Turamnvia, use what you like. A good compiler, good library set is only
as good as the programmer that uses it.
C is fast, small very flexible and somewhat dangerous. The MISRA subset
of C produce better mission critical code, because the richness of the
language is restricted/disallowed.
C++ is an object oriented extension to C. It is an improvement on C, but
IMHO not well suited to small embedded systems. However it depends on
your tools and your writing skills. (Java would be better than C++ for
embedded design, but try finding native compilers!)
ADA provides for concise system description right there within the
language. It works everytime, all the time. It is not prone to code
ambiguity like C and therefore C++, even though all code ambiguity is
the programmers fault.
Every mission critical system I developed or assisted on pre 2001 was
ADA and Occam based. After 2001 some of my employers have switched to
the use of C (adhering to the MISRA subset/controls.) Conversely, pre
and post 2001 every GUI, test tool, front-end, test engine and
instrumentation interface was written in C, C++, Java, Delphi and more
recently C# (quick and dirty).
I've many years of experience in C/C++ (and
Delphi) but no Ada knowledge.
Delphi grew from Turbo Pascal at Borland. ADA is Pascal with necessary
enhancements for mission critical (military) applications. btw VHDL grew
out of ADA.
May I ask if it is too difficult to move from C/C++ to Ada?
You may ask. Answer: it depends on you. IMHO no, but I learned Pascal
before C, OOA/OOD before C++ and ADA after 'Z'. Simply put, the
languages are different, the concepts and methods are different. The
applications are not.
What is the best way of learning Ada for a C/C++ programmer?
Get some books you like. You want a hacker's guides to start with, free
stuff, online manuals, tutorials etc. Make notes and lots of code
snippets; lots and lots of code snippets.
This will get you up and running. Then the heavy stuff later on: set
yourself tasks, projects etc. Discover what tools and methods are
available to perform ADA design on your target system(s).
----------------
Lastly, avoid comparing the languages. Avoid conversations especially
with lecturers and users of more modern languages (c/c++, c# even
Delphi). It will just start arguments.
All programming languages have their niches and some are more suited to
a task than others. Most Aircraft use ADA; Banks use C++; Most
Instrumentation and embedded engineers use C/Assembler (ASM); Most Game
developers use ASM and more recently C; Communication systems requiring
formal definition use CSP & Occam. Schools teach Basic; Colleges teach
C, C#, vb.net or vb; Universities teach Pascal, C, C++, Occam, ADA and
more......
An introduction to cat skinning. (The Abridged War and Peace version)
Good luck and God Bless.