[Info-vax] Memory Safe Programming Languages

Simon Clubley clubley at remove_me.eisner.decus.org-Earth.UFP
Fri Mar 8 08:14:59 EST 2024


On 2024-03-07, bill <bill.gunshannon at gmail.com> wrote:
>
> But my argument is that C had the chance to be one of those
> "safer" languages.  Users rejected it.  Have to wonder why.
>

Did it fix only one special case - buffer overflows - or was it
a safer language in general ? For example, how strong was type
checking in this safer C ?

> And, on another note regarding C and Ada.  The original GNAT
> compiler converted Ada into C and compiled it with GCC.  Now,
> it seems to me that points at two possible concepts.  One is
> that if Ada can be done in C then it has all the same flaws
> and warts.  Not sure I would like to go  in that direction.
> The other is much more interesting.  And that is the concept
> that C can, obviously, be just as safe as Ada.  The question
> then becomes why isn't it?  See my first paragraph.   :-)
>

Well, that's a load of nonsense and shows a total lack of understanding
of how compilers work. All compiled languages are ultimately compiled
into assembly language opcodes. That doesn't mean they are only as safe
as the assembly language they are compiled into.

OTOH, it could sound like the reasoning of someone trying to desperately
claim that C is somehow as safe as Ada. :-)

Also, how long did this GNAT compiler that translated into C
actually exist for ? Was it something that once existed for a couple
of years about 30-35 years ago and was never used again.

I first started really using Ada compilers around the gcc 2.8 timeframe
(IIRC) and have never encountered this Ada to C translator you speak of.

Simon.

-- 
Simon Clubley, clubley at remove_me.eisner.decus.org-Earth.UFP
Walking destinations on a map are further away than they appear.



More information about the Info-vax mailing list