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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.69.13.226 with SMTP id fb2mr29369053pbd.0.1436574547915; Fri, 10 Jul 2015 17:29:07 -0700 (PDT) X-Received: by 10.50.67.100 with SMTP id m4mr34047igt.12.1436574547884; Fri, 10 Jul 2015 17:29:07 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!news.glorb.com!qs7no3658153igc.0!news-out.google.com!a16ni14335ign.0!nntp.google.com!qs7no3658150igc.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 10 Jul 2015 17:29:07 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=118.93.184.33; posting-account=g6PEmwoAAADhFsmVm6Epjviaw4MLU0b5 NNTP-Posting-Host: 118.93.184.33 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Possible bug? From: Anatoly Chernyshev Injection-Date: Sat, 11 Jul 2015 00:29:07 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: news.eternal-september.org comp.lang.ada:26759 Date: 2015-07-10T17:29:07-07:00 List-Id: Right. I guess, I became overrelaxed at Ada's capacity to straighten up whatever stupid things I could put in the code. > > No. What happens is that it constructs an initialization aggregate whose > > bounds are (n_d, 2), and then raises Constraint_Error because the bounds > > of the initial value do not match those of the variable. That's exactly > > what the warning is telling you. > > Right. More generally, "out of range" errors are always reported at runtime; > compilers often give a warning but they're not allowed to reject the > program. That's because perfectly sensible programs might contain an "out of > range" error in code that will never be executed, and one would be very > annoyed if the program was rejected.