From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on ip-172-31-65-14.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-0.0 required=3.0 tests=BAYES_40,FREEMAIL_FROM, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Received: by 2002:a05:6214:621:b0:432:5e0d:cb64 with SMTP id a1-20020a056214062100b004325e0dcb64mr84587355qvx.65.1654762890237; Thu, 09 Jun 2022 01:21:30 -0700 (PDT) X-Received: by 2002:a25:c711:0:b0:65c:9f45:64e5 with SMTP id w17-20020a25c711000000b0065c9f4564e5mr37654822ybe.189.1654762890062; Thu, 09 Jun 2022 01:21:30 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.uzoreto.com!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 9 Jun 2022 01:21:29 -0700 (PDT) In-Reply-To: Injection-Info: google-groups.googlegroups.com; posting-host=202.67.103.232; posting-account=S_MdrwoAAAD7T2pxG2e393dk6y0tc0Le NNTP-Posting-Host: 202.67.103.232 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Extra information in the message string of exceptions. From: Robin Vowels Injection-Date: Thu, 09 Jun 2022 08:21:30 +0000 Content-Type: text/plain; charset="UTF-8" X-Received-Bytes: 1941 Xref: reader02.eternal-september.org comp.lang.ada:63956 List-Id: On Monday, June 6, 2022 at 11:02:25 PM UTC+10, roda...@gmail.com wrote: > Hi all, > > Any thoughts on pro's/con's of having the Ada standard packages > runtime provide extra information in the message string of exceptions ? > > For instance, a Constraint_Error message might provide details on > the variable name, the legal range and the erroneous value which caused > the exception. . PL/I provides a description of an error, e.g. mentioning the condition that has been raised, e.g., SUBSCRIPTRANGE, ZERODIVIDE. The user can then take control and print the value of a variable or values of any group of variables. E.g., for a SUBSCRIPTRANGE error, the user can also print the upper and lower bounds of the array, though this is usually not done, it being sufficient to print the name of the variable(s) and value(s).