Mail Archives: cygwin/2005/07/05/16:27:33
The release notes for 1.5.18 state that strtoimax was added. But compare
the output of the following:
$ uname -a
CYGWIN_NT-5.0 eblake 1.5.18(0.132/4/2) 2005-07-02 20:30 i686 unknown unknown Cygwin
$ cat > foo.c
#include <stdio.h>
#include <inttypes.h>
int main(int argc, char**argv)
{
printf("%lld\n", strtoimax("1", NULL, 0));
return 0;
}
$ gcc -o foo foo.c
/cygdrive/c/DOCUME~1/eblake/LOCALS~1/Temp/ccQLtRpQ.o:foo.c:(.text+0x42): undefined reference to `_strtoimax'
collect2: ld returned 1 exit status
$ gcc -o foo -mno-cygwin foo.c
$ ./foo
1
Also, there is a bug with strtoll (which cygwin.din claims should be the base
of strtoimax):
$ cat > foo.c
#include <stdio.h>
#include <inttypes.h>
int main(int argc, char**argv)
{
printf("%llx\n", strtoll("1", NULL, 10));
return 0;
}
$ gcc -o foo foo.c
$ ./foo
a00000001
$ gcc -o foo -mno-cygwin foo.c
$ ./foo
1
--
Eric Blake
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
- Raw text -