comp.lang.ada
 help / color / mirror / Atom feed
From: Pascal Obry <pascal@obry.net>
Subject: Re: With Exceptions Disabled On Windows, How Can I Determine Where A  Software Interrupt Occurs
Date: Tue, 20 Oct 2009 20:23:15 +0200
Date: 2009-10-20T20:22:59+02:00	[thread overview]
Message-ID: <4ade0003$0$966$ba4acef3@news.orange.fr> (raw)
In-Reply-To: <7091f995-dd7e-4442-8ca5-158b83e50bec@x5g2000prf.googlegroups.com>

Le 20/10/2009 20:01, ChristopherL a �crit :
> I'm looking for a compilable/working example on how to do this. For
> example code to determine where a divide by zero occurs etc.

With GNAT?

Nothing, you should get something like this when running your application:

    raised CONSTRAINT_ERROR : buf.adb:12 divide by zero

> If I can't get the code what can you tell me?

To have full backtrace and also check for overflow you should compile 
your application with -gnato and pass -E on the binder:

    $ gnatmake prog -cargs -gnato -bargs -E

Pascal.

-- 

--|------------------------------------------------------
--| Pascal Obry                           Team-Ada Member
--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE
--|------------------------------------------------------
--|    http://www.obry.net  -  http://v2p.fr.eu.org
--| "The best way to travel is by means of imagination"
--|
--| gpg --keyserver keys.gnupg.net --recv-key F949BD3B




       reply	other threads:[~2009-10-20 18:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <7091f995-dd7e-4442-8ca5-158b83e50bec@x5g2000prf.googlegroups.com>
2009-10-20 18:23 ` Pascal Obry [this message]
2009-10-20 18:37   ` With Exceptions Disabled On Windows, How Can I Determine Where A Software Interrupt Occurs Dmitry A. Kazakov
2009-10-20 18:43     ` Pascal Obry
2009-10-20 19:04       ` Dmitry A. Kazakov
2009-10-21 10:53     ` Georg Bauhaus
2009-10-20 20:50   ` sjw
     [not found] <b0d7911b-cb10-4fb2-a977-da865b8b2001@u16g2000pru.googlegroups.com>
2009-10-20 19:31 ` Keith Thompson
replies disabled

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