[cfe-dev] printf typechecking -- invalid conversion '%p

Keith Bauer onesadcookie at gmail.com
Sat Aug 25 18:18:08 PDT 2007


Also at Chris' request:

imac:Desktop keith$ cat > test4.c
int printf(const char *fmt, ...);

void foo(void *p) {
    printf("%p\n", p);
}
imac:Desktop keith$ clang -fsyntax-only test4.c
test4.c:4:13: warning: invalid conversion '%p
'
    printf("%p\n", p);
    ~~~~~~  ^
1 diagnostic generated.

-Keith



More information about the cfe-dev mailing list