comp.lang.ada
 help / color / mirror / Atom feed
From: f97stdi@dd.chalmers.se (Staffan Dittmer)
Subject: Re: Catching NaN .. not a number
Date: 5 May 2001 18:28:43 GMT
Date: 2001-05-05T18:28:43+00:00	[thread overview]
Message-ID: <9d1gor$4l2$1@eol.dd.chalmers.se> (raw)
In-Reply-To: slrn9f8fv0.17m.randhol+abuse@kiuk0156.chembio.ntnu.no

In article <slrn9f8fv0.17m.randhol+abuse@kiuk0156.chembio.ntnu.no>,
	randhol+abuse@pvv.org (Preben Randhol) writes:

>When you say calculating factorial, do you use integer?
 
No, long_float. Works up to ~ 170! for me, at least I believe so....


>         For floating-point, GNAT has the `Machine_Overflows'
>         attribute set to `False' and the normal mode of operation is to
>         generate IEEE NaN and infinite values on overflow 
> 

Ok, so since I'm using Gnat and long_floats, I would expect a NaN on
overflow. 
Is NaN a value in itself? Is it possible to do a check like 
if result = NaN then ...  ?

/ Staffan Dittmer



  reply	other threads:[~2001-05-05 18:28 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-05-05 17:46 Catching NaN .. not a number Staffan Dittmer
2001-05-05 17:58 ` Preben Randhol
2001-05-05 18:28   ` Staffan Dittmer [this message]
2001-05-05 21:50 ` Keith Thompson
2001-05-07 21:40   ` Stephen Leake
2001-05-08  1:37     ` 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