cygwin gcc 2.95-2 printf bug

Gerald Jansen gjansen@uoguelph.ca
Sun Jan 28 11:10:00 GMT 2001


There is a bug printing near-zero floating point numbers in 2.95.2.
main() {
 printf("[%5.2f] [%5.2f]\n",0.01,-0.01);
 printf("[%5.2f] [%5.2f]\n",0.001,-0.001);
 exit(0);
}
Produces:
[ 0.01] [-0.01]
[ 0] [-0]
gcc -v on my Windows 2000 machine gives:
Reading specs from /usr/lib/gcc-lib/i686-pc-cygwin/2.95.2-6/specs
gcc version 2.95.2-6 19991024 (cygwin experimental)
The correct result occurs on two other platforms:
Reading specs from
/usr/local/opt/gcc/lib/gcc-lib/hppa1.1-hp-hpux10.20/2.8.1/specs
gcc version 2.8.1
and:
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 20000731 (Red Hat Linux 7.0)
Gerald Jansen
--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple


More information about the Cygwin mailing list

AltStyle によって変換されたページ (->オリジナル) /