comp.lang.ada
 help / color / mirror / Atom feed
From: jrmonroe@aol.com (JRMONROE)
Subject: Re: GNAT 3.05 distribution, Float Exception Handling Error
Date: 1996/09/15
Date: 1996-09-15T00:00:00+00:00	[thread overview]
Message-ID: <51ic3u$t7r@newsbf02.news.aol.com> (raw)
In-Reply-To: dewar.842783560@schonberg


I use a 486/66, 16megs ram, Dos ver 6.22, wFw3.11, also win95 ,but the
win95 gnat works fine.  The dos gnat305 is not working for this floating
point error.  I tried the following code and it gives me the following
error:

with ada.text_io, ada.float_text_IO;
use ada.text_io, ada.float_text_io;
procedure Testing is
    -- declarations
    a:float:=20.0;
    b:float:=5.0;
    c:float:=0.0;
    
    test:exception;
begin
    -- statements
    begin -- begin block
    put_line("THIS IS A TEST");
    new_line;
    put("20/5= ");
    put(a/b);
    new_line;
    put("20/0=");
    put(a/c);
    exception
    	when constraint_error =>
    		put_line("CONSTRAINT ERROR");
    	when others =>
    		put_line("some other error was made");	
    		
    end; --block
    Put_line("THIS SHOULD BE AFTER EXCEPTION!!");
    
end Testing;

Error is:
Exiting due to signal SIGFPE
Floating Point exception at eip=0000c19d
eax=00000002 ebx=0005efec ecx=00000005 edx=0001ef40 esi=00000054
edi=0001f044
ebp=0005f014 esp=0005efb8 cs=00af ds=00b7 es=00b7 fs=0087 gs=00c7 ss=00b7
Call frame traceback EIPs:
  0x0000c19d
  0x000015da
  0x0000d707

Any help would be appreciated, thank you sincerely,

James R. Monroe
USAF Retired




  reply	other threads:[~1996-09-15  0:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-09-14  0:00 GNAT 3.05 distribution, Float Exception Handling Error JRMONROE
1996-09-15  0:00 ` David C. Hoos, Sr.
1996-09-15  0:00 ` Robert Dewar
1996-09-15  0:00   ` JRMONROE [this message]
1996-09-16  0:00     ` David C. Hoos, Sr.
replies disabled

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