I'm trying to define an IEEE floating-point constant whose value should be +infinity, but I'm getting errors from icc 7.0:
foo.c(3): error: expression must have a constant value
static const double totor=INFINITY;
The same code is accepted without a complaint by gcc.
C99 defines the constant INFINITY, but the definition from glibc is not accepted by icc:
My opinion is that icc should
1. (Re)define INFINITY in its if it cannot cope with the definition from glibc.
2. Accept 1.0/0.0 with a _warning_, not an _error_.