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=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!v102.xanadu-bbs.net!xanadu-bbs.net!nntp.club.cc.cmu.edu!micro-heart-of-gold.mit.edu!newsswitch.lcs.mit.edu!nntp.TheWorld.com!.POSTED!not-for-mail From: Robert A Duff Newsgroups: comp.lang.ada Subject: Re: Differences between Ada 83 and other revisions Date: Wed, 19 Feb 2014 17:58:05 -0500 Organization: The World Public Access UNIX, Brookline, MA Message-ID: References: <19ac8735-7a9c-429f-a111-a1b3c4b0985b@googlegroups.com> <3872de7d-2df4-4ddb-8348-45eb03b3588e@googlegroups.com> <6aca36a4-cd78-4098-a1f7-646cb37cd14d@googlegroups.com> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: pcls7.std.com 1392850689 870 192.74.137.71 (19 Feb 2014 22:58:09 GMT) X-Complaints-To: abuse@TheWorld.com NNTP-Posting-Date: Wed, 19 Feb 2014 22:58:09 +0000 (UTC) User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.3 (irix) Cancel-Lock: sha1:OMrXLkQnJ0Xrd+ngXwMa31cU+MY= Xref: news.eternal-september.org comp.lang.ada:18688 Date: 2014-02-19T17:58:05-05:00 List-Id: adambeneschan@gmail.com writes: > On Wednesday, February 19, 2014 2:09:31 PM UTC-8, Robert A Duff wrote: > >> (C is far worse in that regard!) > > It's actually very easy to list all the unsafe features of C. > > 1) C ;-) Yeah, I guess that's one way to look at it. In C, array indexing, addition, multiplication, and many other commonly-used features are all unsafe. In the original K&R C, even function calls were unsafe, but fortunately they (mostly) fixed that. To be fair, pointer dereferencing is unsafe in both Ada and C, so the feature I was asking for ("find all usage of unsafe features") wouldn't work very well even in Ada -- too many false alarms. Pointer dereferencing could be made safe. - Bob