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=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,78447032bdbeb343 X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!news1.google.com!postnews.google.com!k30g2000hse.googlegroups.com!not-for-mail From: =?ISO-8859-1?Q?Santiago_Urue=F1a?= Newsgroups: comp.lang.ada Subject: Re: Proposal: pragma Assumption Date: Wed, 28 May 2008 00:58:48 -0700 (PDT) Organization: http://groups.google.com Message-ID: <13aa4422-c478-478e-8e33-882508d9d1f8@k30g2000hse.googlegroups.com> References: <30917be5-1446-417c-8a4e-18b2f9a1f420@b1g2000hsg.googlegroups.com> NNTP-Posting-Host: 138.4.11.35 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1211961528 15285 127.0.0.1 (28 May 2008 07:58:48 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 28 May 2008 07:58:48 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: k30g2000hse.googlegroups.com; posting-host=138.4.11.35; posting-account=Lcd2wAoAAAADW2SqWO5AWY55Q-jjpVWU User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; es-ES; rv:1.8.1.10) Gecko/20071115 Iceweasel/2.0.0.10 (Debian-2.0.0.10-0etch1),gzip(gfe),gzip(gfe) Xref: g2news1.google.com comp.lang.ada:412 Date: 2008-05-28T00:58:48-07:00 List-Id: > So the proposal would be adding to the next Ada revision two new > pragmas: > > pragma Assumption ([Check =3D>] boolean_expression[, > [Message =3D>] string_expression]); > pragma Assumption_Policy (policy_identifier); -- Error, Check > I've been thinking more about it, and probably the compilers should be encouraged to choose a long switch name to reduce the chance of forgetting to remove that it in the final binary. For example, instead of (say) "-gnatap", choose something like "--allow-unimplemented- units". And maybe the pragma Assumption_Policy is a bad idea for the same reasons: this pragma has preference over the compiler switches (at least for gnat in the case of pragma Assert_Policy), so it is very easy to forget to change the policy from "Check" to "Error"... -- Santiago Urue=F1a-Pascual Technical University of Madrid (UPM)