www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/01/06/11:18:36

Date: Thu, 6 Jan 2000 13:47:29 +0100 (CET)
From: Wilmer van der Gaast <lintux AT dds DOT nl>
To: djgpp AT delorie DOT com
Subject: Re: DJGPP BUG!!!!!!! ???
In-Reply-To: <851o9m$h4t$1@news.lth.se>
Message-ID: <Pine.LNX.4.10.10001061343100.2453-100000@syscon.minilinux.org>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: dj-admin AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Thu, 6 Jan 2000, Niklas Pettersson wrote:

> Hello!
> 

> ............

> but 1.0 gets converted to 0!!!!
> and even worse, 2.0 gets converted to 2... strange.. not a general
> behaviour...
> 
> Is this a bug or is it me that are to dumb? (I have coded almost the whole
> night)...
You might say the Intel-guys are dumb, maybe...

> 
> Any comments are appreciated
> 
> / Niklas

Ha, we were having the same problem at the Dutch Olympiad of Informatics(??).
You can add 0.0001, or a smaller number, and it works.
It's not a compiler bug, QB45 does it, GCC/Linux does it, GCC/DJGPP does it,
I haven't tested it on FreeBSD yet. It's because the CPU stores FP numbers in
a way that doesn't look like integers.

---------

Wilmer van der Gaast (lintux AT dds DOT nl)
ICQ 55707076

- Raw text -


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