delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/10/12/08:32:46

Date: Sun, 12 Oct 1997 14:29:33 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Reinier Heeres <rwh AT worldonline DOT nl>
cc: djgpp AT delorie DOT com
Subject: Re: DJGPP, floating point problems?!?
In-Reply-To: <343FEFAC.587C3829@worldonline.nl>
Message-ID: <Pine.SUN.3.91.971012142849.8447W-100000@is>
MIME-Version: 1.0

On Sat, 11 Oct 1997, Reinier Heeres wrote:

> It seems to me that DJGPP v2.0 has some trouble with floating point,
> look at this code:
> 
> p->s_x=p->r_v.x;
> 
> (Where s_x is an int, and r_v.x is a float)
> 
> This code will always produce a floating point exceptions, why??? Can
> anybody please help me to solve this???

Please post at least the value in p->r_v.x.  You don't really suppose
people here can guess what's wrong with your program without seeing
the data?

In general, assigning a floating point number to an int works for me.
Maybe in your program r_v.x gets a NaN or a garbled value.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019