wprintf warning
Jim Marshall
jim.marshall@wbemsolutions.com
Wed May 7 21:30:00 GMT 2003
Hello,
I'm sure this has been asked before, but UI can not find the answer via
searching this list or on google. I'm testing out the use of wchar.h for
a project I'm working on, I wrote a simple "Hello World" program, but it
gives me a warning when it is compiled with -Wall:
/* wprint_test.c */
#include <stdio.h>
#include <wchar.h>
int main(int argc, char** argv) {
wprintf(L"Hello World\n");
return 0;
}
When I compile this with -Wall I get:
cc -Wall wprint_test.c
wprint_test.c: In function 'main':
wprint_test.c:5: warning: implicit declaration of function 'wprintf'
what do I need to do to compile with -Wall and not get this warning (I
have tried adding -D__USE_ISOC99 and -D__USE_UNIX98). Is it possible?
Using gcc 3.2 20020903 (Red Hat Linux 8.0 3.2-7)
Thank you
More information about the Gcc
mailing list