delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1995/08/17/08:30:28

Xref: news-dnh.mv.net comp.os.msdos.djgpp:1609
Path: news-dnh.mv.net!mv!news.sprintlink.net!howland.reston.ans.net!tank.news.pipex.net!pipex!oleane!jussieu.fr!univ-lille1.fr!cict.fr!news
From: poulard AT laas DOT fr (Herve Poulard)
Newsgroups: comp.os.msdos.djgpp
Subject: Bug in float.h (V1) ?????
Date: 17 Aug 1995 08:46:10 GMT
Organization: LAAS/CNRS Toulouse France
Lines: 25
References: <DD104u DOT HEK AT freenet DOT carleton DOT ca>
Reply-To: poulard AT laas DOT fr
Nntp-Posting-Host: gandala.laas.fr
To: djgpp AT sun DOT soe DOT clarkson DOT edu
Dj-Gateway: from newsgroup comp.os.msdos.djgpp

Hello,
I think I have perhaps found a bug.
I was trying to port a unix based program
on PC with djgpp and I didn't work
because of a bad declaration of DBL_MAX
in float.h.
We have
float.h:#define DBL_MAX         1.7976931348623167e+308
the internal representation is  000000000000f07f
But I think the correct value is 
#define	DBL_MAX		        1.7976931348623157E+308
the internal representation is  ffffffffffffef7f
as on gcc on unix system, like other compiler on PC 
(borlandc)
This little difference .....67 instead of .....57
caused a completly bugged behavior in the program.

 Any comments ??????

Herve POULARD

poulard AT laas DOT fr


- Raw text -


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