isfinite macro defined for 4.4.1 but not for 4.3.3
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gcc-4.3 (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: gcc-4.3
Originally, I reported this problem to GCC team (http://
The problem is that the definition of isfinite() macro is not consistent
between version of GCC 4.3.3 and GCC 4.4.1 (so, it is related to package of GCC 4.4 in Ubuntu 9.10 as well)
Simple test program:
include <math.h>
#ifdef isfinite
#error isfinite defined
#else
#error isfinite NOT defined
#endif
int main() { return 0; }
1) Test with GCC 4.4.1 (Ubuntu 9.10 x86-64)
mloskot@dog:~/tmp$ gcc --version
gcc (Ubuntu 4.4.1-4ubuntu9) 4.4.1
mloskot@dog:~/tmp$ gcc isfinite.c
isfinite.c:3:2: error: #error isfinite defined
mloskot@dog:~/tmp$
2) Test with GCC 4.3.3 (Ubuntu 9.04 x86-32)
mloskot@
gcc (Ubuntu 4.3.3-5ubuntu4) 4.3.3
mloskot@
isfinite.c:5:2: error: #error isfinite NOT defined
In the 2nd case, it seems to be required to use compiler option -std=c99 to
enable the macro:
mloskot@
isfinite.c:3:2: error: #error isfinite defined
I think the behaviour of version 4.3.3. is incorrect.
I didn't find any related reports in GCC Bugzilla except the one for C++ use of iostream.h
together with math.h (http://
But I am sure it is not related to this report.
not reproducible anymore with lucid's gcc-4.3 and gcc-4.4