comp.lang.ada
 help / color / mirror / Atom feed
From: marciant@earthlink.net
Subject: Re: GNAT user-specified (via Raise_Exception) warning message size limit
Date: Sat, 17 Feb 2018 08:38:03 -0800 (PST)
Date: 2018-02-17T08:38:03-08:00	[thread overview]
Message-ID: <5b7b1d2f-5c1a-453b-b5e8-590ff8842b77@googlegroups.com> (raw)
In-Reply-To: <p68nu1$9i2$1@dont-email.me>

On Saturday, February 17, 2018 at 3:08:35 AM UTC-5, J-P. Rosen wrote:
> Le 17/02/2018 à 00:22, marc...@earthlink.net a écrit :
> > Some XML text messages are being parsed "deep" down in a subsystem
> > and when a problem is encountered a specific exception is raised and
> > the problematic XML text is included in the exception message and
> > propagated up a "level" or two of code where it is sometimes parsed
> > again and repropagated with additional debugging information.
> But why do you put all the message in the exception message?
> 
> Store it in some global structure, where you can handle it any way you
> want. Note that it's what you'd do if you wanted to keep information
> other than string (assuming you have no issue with concurrency, but then
> you could use a task attribute)

In the exception message for a few reasons:
- The information was always all text (an externally produced structured message)
- The final length was always unknown
- All debugging/logging "machinery" was originally designed to expect to only have to simply print out Exception_Information.
- For years it had all fit (including full/deep, explicit ObjectAda call trace back debugging information)
- Design for portability was never a requirement: The project was supposed to have been superseded a few times already by (non-Ada) projects that themselves ended up being cancelled.

However, like you suggested, I understand that using a global area (possibly indictated by "place-holder" text that is put in the exception message instead of the actual text) might be made to work with minimal disruption to the existing code.

Thanks,
Vincent Marciante

  reply	other threads:[~2018-02-17 16:38 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-16 18:44 GNAT user-specified (via Raise_Exception) warning message size limit marciant
2018-02-16 18:59 ` Per Sandberg
2018-02-16 19:11   ` marciant
2018-02-16 20:58     ` Anh Vo
2018-02-16 23:22       ` marciant
2018-02-17  7:15         ` J-P. Rosen
2018-02-17 16:38           ` marciant [this message]
2018-02-18 22:33     ` Mark Lorenzen
2018-02-18 23:09       ` Simon Wright
2018-02-19  7:24         ` briot.emmanuel
2018-02-19 15:31       ` marciant
2018-02-22 15:08         ` marciant
2018-02-22 19:48           ` marciant
2018-02-22 20:27             ` Simon Wright
2018-02-22 21:43               ` Mark Lorenzen
2018-02-22 22:09               ` marciant
2018-02-23  8:25               ` briot.emmanuel
2018-02-23  8:56                 ` Simon Wright
2018-02-17  0:03 ` Randy Brukardt
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox