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!mx02.eternal-september.org!.POSTED!not-for-mail From: Jeffrey Carter Newsgroups: comp.lang.ada Subject: Re: How to get nice with GNAT? Date: Tue, 25 Nov 2014 09:52:35 -0700 Organization: Also freenews.netfront.net; news.tornevall.net; news.eternal-september.org Message-ID: References: <0d8452a9-68c9-4835-b6f3-17407132ca9f@googlegroups.com> <8194a204-7b15-463d-a2fd-4d3ba342fe97@googlegroups.com> <8f203a9a-6c7c-4614-bc7d-efa65bf10776@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Injection-Date: Tue, 25 Nov 2014 16:52:22 +0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="6bb4f0a3c21c874c69dbcaa30e818f24"; logging-data="22960"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18XzqmbjHT2B/I/Ne0vxW8ttGQTRpb6FSI=" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 In-Reply-To: <8f203a9a-6c7c-4614-bc7d-efa65bf10776@googlegroups.com> Cancel-Lock: sha1:ntGWZy849V3pbdyRWTVRwR/bGbs= Xref: news.eternal-september.org comp.lang.ada:23714 Date: 2014-11-25T09:52:35-07:00 List-Id: On 11/25/2014 08:07 AM, ake.ragnar.dahlgren@gmail.com wrote: > > Of course I always listen seriously to Jeff Carter but it's not obvious to me > that doing "C in Ada" is bad. If I remember correctly Google employees are > recommended to avoid using exceptions when doing C++. The designers of Google > Go has gone great lengths to avoid the exception concept as much as possible. We have decades of experience with C that shows that humans cannot use it safely on real-world problems. Ignoring error codes is part of that problem. I think it's clear the C mind set should not be emulated. As to Google and Go, if they were worth listening to, they'd be using Ada :) > In addition SPARK forbids usage of exceptions. SPARK also requires proof that exceptions won't occur, and proof that error codes are not ignored. C would be a much better language if it required proof that error codes are not ignored, and arrays are never indexed past their bounds, and proof ... -- Jeff Carter "I was in love with a beautiful blonde once, dear. She drove me to drink. That's the one thing I'm indebted to her for." Never Give a Sucker an Even Break 109