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=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,1a4156f047b063f X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!goblin1!goblin.stu.neva.ru!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail From: Ludovic Brenta Newsgroups: comp.lang.ada Subject: Re: Forcing Exception Handling Date: Mon, 28 Feb 2011 21:35:03 +0100 Organization: A noiseless patient Spider Message-ID: <87y64zucco.fsf@ludovic-brenta.org> References: <02901b13-da72-48ae-9cb3-bf1a10144c44@u3g2000vbe.googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: mx03.eternal-september.org; posting-host="QyVJj6mNDwpF2dGh28S43w"; logging-data="7500"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+Y/sy9TnKum1OLCR/q68BY" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) Cancel-Lock: sha1:UBdLooOWt5KpdKk3thTkwgbTLsc= sha1:eAGA78waoTSX7sUpj395WxQ+egk= Xref: g2news2.google.com comp.lang.ada:18620 Date: 2011-02-28T21:35:03+01:00 List-Id: iloAda writes: > Hello everybody, > > I was wondering if there is a way in Ada to force exception handling. > For instance, if there is a call to a function that may raise an > exception, force the caller to handle that exception. > I was wondering if there is a compile time pragma that will isntruct > the compiler to force the handling of exceptions!! I think the Ada Rapporteur Group considered the idea and rejected it. I seem to remember they had good reasons but I forgot which they were. Maybe the first was that pretty much any statement can raise Storage_Error, and that Program_Error can be raised during elaboration, when there is no exception handler in place yet. -- Ludovic Brenta.