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,7a3b1c6915ea1273 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.190.99 with SMTP id gp3mr353479pbc.1.1326414068268; Thu, 12 Jan 2012 16:21:08 -0800 (PST) MIME-Version: 1.0 Path: lh20ni175532pbb.0!nntp.google.com!news1.google.com!goblin3!goblin1!goblin.stu.neva.ru!news.tornevall.net!news.jacob-sparre.dk!pnx.dk!jacob-sparre.dk!ada-dk.org!.POSTED!not-for-mail From: "Randy Brukardt" Newsgroups: comp.lang.ada Subject: Re: How many Ada compiler bugs are here? Date: Thu, 12 Jan 2012 18:21:01 -0600 Organization: Jacob Sparre Andersen Research & Innovation Message-ID: References: <01dd6341-9c3c-4dcb-90f8-6ac66c65eb66@z1g2000vbx.googlegroups.com> NNTP-Posting-Host: static-69-95-181-76.mad.choiceone.net X-Trace: munin.nbi.dk 1326414066 5005 69.95.181.76 (13 Jan 2012 00:21:06 GMT) X-Complaints-To: news@jacob-sparre.dk NNTP-Posting-Date: Fri, 13 Jan 2012 00:21:06 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.5931 X-RFC2646: Format=Flowed; Original X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 Date: 2012-01-12T18:21:01-06:00 List-Id: "Maciej Sobczak" wrote in message news:01dd6341-9c3c-4dcb-90f8-6ac66c65eb66@z1g2000vbx.googlegroups.com... ... > 1. Adjust should not be allowed to be declared (it is a *limited* > type). But I have defined it to trace the remaining bugs: There's nothing wrong with defining "Adjust" (you can define any named subprogram you want, of course), but (A) "overriding" shouldn't be allowed on it, and (B) it shouldn't be called automatically if it is defined without "overriding", because it is not special for a limited type. > 2. The return statement in Make_T should not be required, because it > is unreachable anyway. Ada requires all functions to have a return statement. 6.5(5/2). This was an Ada 83 rule; we've discussed removing it, but the feeling was that it catches as many errors as it creates, and we just couldn't justify a change to the language that didn't seem to be an obvious improvement. (In my personal work, it has been about 50-50 as to whether it helps or hinders.) So the requirement for a return statement is not a bug, it's a language rule. > 3. Logically, Tmp is never created, because Make_T raises an > exception. Somehow some object is finalized. Apparently it is Tmp, > which should not exist. > 4. Somehow Tmp.initialized = True, even though its default value is > defined to be False. I'm not sure if these are actually bugs or not; the fact that Adjust is being called for a limited object means to me that nothing that happens afterwards makes any sense from a formal language perspective, so you can't really say if there is a bug. Garbage-in, garbage-out! Does the same thing happen without Adjust being defined? That would seem more like a bug. Randy.