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,3f92589f15917eec X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!o21g2000prn.googlegroups.com!not-for-mail From: jpwoodruff Newsgroups: comp.lang.ada Subject: Re: Simple Warnings Needs Date: Wed, 23 Feb 2011 15:07:16 -0800 (PST) Organization: http://groups.google.com Message-ID: <10a06ab9-0878-415d-9050-66de0a51e54b@o21g2000prn.googlegroups.com> References: NNTP-Posting-Host: 24.4.0.129 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1298503402 20361 127.0.0.1 (23 Feb 2011 23:23:22 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 23 Feb 2011 23:23:22 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: o21g2000prn.googlegroups.com; posting-host=24.4.0.129; posting-account=eLk0BgoAAAA-yA75xm1L7heSizMaESVg User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.13) Gecko/20101203 Firefox/3.6.13,gzip(gfe) Xref: g2news1.google.com comp.lang.ada:17570 Date: 2011-02-23T15:07:16-08:00 List-Id: On Feb 23, 11:56=A0am, mockturtle wrote: > On Wednesday, February 23, 2011 7:52:37 PM UTC+1, Rego wrote: > > I would like to know (in more details than gnat documentation) the crit= icality of these warnings options: > > =A0** "-gnatwd" (Implicit dereferencing) > > =A0** "-gnatwf" (Unreferenced formals) > > =A0** "-gnatwh" (Hiding) > > =A0** "-gnatwm" (Modified but unreferenced variables) > > =A0** "-gnatwk" (Variables that could be constants) > > > About "-gnatwf" (Unreferenced formals), "-gnatwm" (Modified but unreferen= ced variables) =A0I think that the idea is to warn about "strange" construc= t: why did you modify that variable if you are not reading it again? =A0Thi= s is strange and maybe it is the consequence of an error. =A0Again, the ris= k is having a program with a bug rather than a security threat. > I think I'd like these if I were "adjusting" some old code. Suppose I added a requirement to some good quality code. I'll look for the warning when I'm done modifying, so I'll see if I left some artifact that should have been considered when I modify. John