Hi,

Got it. However on Windows, v. GPL 2016 (but it might be a behaviour unexpected 
by AdaCore), the exception is a PROGRAM_ERROR: ACCESS_VIOLATION.

I'll give a try by adding a handler for PROGRAM_ERROR (sounds clumsy...).


For my understanding: in order to get the exception messages during execution, 
I guess you have enabled this :

GNAT.Exception_Traces.Trace_On (GNAT.Exception_Traces.Every_Raise);

?

________________________________
From: Pascal via Gnoga-list <gnoga-list@lists.sourceforge.net>
Sent: Wednesday, June 7, 2017 10:17:06 AM
To: Gnoga support list
Cc: Pascal
Subject: Re: [Gnoga-list] Gnoga.Server.Connection issue with GNAT

Hello Gautier,

Anyway, with checks on or off, an exception is raised.
The difference is the detailed information you get with checks on:

cmd$ gnatmake -s test17
gcc -c test17.adb
gnatbind -x test17.ali
gnatlink test17.ali

cmd$ ./test17
P_OK: Key A not found
P_OK: Key A found, element= 1
P_KO: Key B not found
raised CONSTRAINT_ERROR : Test17.T_Dic.Element: no element available because 
key not in map

P_KO: Key B found, element= 2

Poor information with checks off:

cmd$ gnatmake -s -gnatp test17
gcc -c -gnatp test17.adb
gnatbind -x test17.ali
gnatlink test17.ali

cmd$ ./test17
P_OK: Key A not found
P_OK: Key A found, element= 1
P_KO: Key B not found
raised CONSTRAINT_ERROR : erroneous memory access

P_KO: Key B found, element= 2

But in Gnoga code, whatever the checks activation, the exception 
Connection_Error is raised with detailed information.
Is it correct for you in this particular case?
Else feel free to open a ticket.

Regards, Pascal.
http://blady.pagesperso-orange.fr


> Le 6 juin 2017 à 23:43, Gautier de Montmollin <gdem...@hotmail.com> a écrit :
>
> Le 06.06.2017 à 19:34, Jeffrey R. Carter a écrit :
>> On 06/06/2017 06:13 PM, Gautier de Montmollin wrote:
>>> Anyway, the reason of my message is that the concerned part is in
>>> Gnoga.*, not in my own program.
>>>
>> The reason for my message is to point out that, unless you're sure about all 
>> of
>> the code in your program, you'd better not suppress checks.
> Could not agree more! But again, it is not my program.
>> The only justification for suppressing checks is that there's no other way to
>> meet the timing requirements. In many decades of using languages with 
>> run-time
>> checks, I've never encountered such a situation.
> Lucky you!
>
> Now, you cannot expect everybody not having to suppress checks at any
> point in time.
> Since Gnoga is meant to be a library for a broad usage (the 'o' in
> "omnificent") and used by various people, it is better to make it
> bullet-proof and work with different sets of GNAT options - even those
> you don't like or, in this special case, make the RTL not compliant with
> the Ada standard.
>
> G.
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Gnoga-list mailing list
> Gnoga-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gnoga-list


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gnoga-list mailing list
Gnoga-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gnoga-list
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gnoga-list mailing list
Gnoga-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gnoga-list

Reply via email to