ID Number: Q71423
6.00 6.00a 6.00ax | 6.00 6.00a
MS-DOS | OS/2
buglist6.00 buglist6.00a buglist6.00ax fixlist7.00
Summary:
SYMPTOMS
When compiling and linking certain code with the alternate math
library (/FPa) in C version 6.0, 6.0a, or 6.0ax, the following LINK
error may be generated:
error L2029: '__aFeldt': unresolved external
This error seems to occur only when the following two conditions
have been met:
- The code is compiled for large (/AL) or compact (/AC) memory
model.
- The code dereferences pointers to long doubles.
CAUSE
The last letter of an internal math helper routine indicates size.
An "s" indicates single precision, "d" indicates double precision,
and "t" indicates long double precision. Long doubles are not
supported in alternate math; therefore, the call to __aFeldt is
incorrectly generated and will go unresolved.
RESOLUTION
To work around the error, either use the emulator or 80x87 math
libraries, or compile and link for small (/AS) or medium (/AM)
model, if possible.
The C 7.0 compiler generates the appropriate warning:
C4792: long double type not supported by alternate math library
STATUS
Microsoft has confirmed this to be a problem in C versions 6.0,
6.0a, and 6.0ax. This problem was corrected in C version 7.0.
More Information:
The following sample code illustrates this problem:
Sample Code
-----------
/* Compile options needed: /FPa /AL (or /AC)
*/
void main(void)
{
long double *a, *b, c;
c = *a * *b;
}
Additional reference words: 6.00 6.00a 6.00ax aFeldt _aFeldt