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,5312057f44240abb X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.0.170 with SMTP id 10mr26709232pbf.2.1323174315414; Tue, 06 Dec 2011 04:25:15 -0800 (PST) Path: lh20ni75694pbb.0!nntp.google.com!news2.google.com!volia.net!news2.volia.net!feed-A.news.volia.net!news.musoftware.de!wum.musoftware.de!news.swapon.de!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: AUnit: access to local procedure needed when asserting exception Date: Tue, 06 Dec 2011 12:25:13 +0000 Organization: A noiseless patient Spider Message-ID: References: <4edd6c0a$0$6581$9b4e6d93@newsspool3.arcor-online.net> Mime-Version: 1.0 Injection-Info: mx04.eternal-september.org; posting-host="dFCm8HWntFqmDIilBLqEJQ"; logging-data="27703"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18h7URHV/VkTmXpqSzYQEIg+LKPaXG+G7g=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (darwin) Cancel-Lock: sha1:gTPZutlPQRDcPUImU6bd2VHrNRI= sha1:3DRaU3C1SHFyZHr6EpzxMWPHiy4= Xref: news2.google.com comp.lang.ada:14856 Content-Type: text/plain; charset=us-ascii Date: 2011-12-06T12:25:13+00:00 List-Id: Georg Bauhaus writes: > Consequently, when seeing procedure Test_Null mostly reproduced below, > the compiler diagnoses (correctly, I think) > > 66. AUnit.Assertions.Assert_Exception (Null_Raises'Access, > | > >>> subprogram must not be deeper than access type At this point I tend to just use 'Unrestricted_Access. I've never quite understood the point of this facility, what's wrong with begin -- do whatever should raise The_Exception Assert (C, False, "should have raised The_Exception"); exception when The_Exception => null; end;