https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56724
--- Comment #12 from Tom Tromey <tromey at gcc dot gnu.org> --- I noticed this patch today and tried it out on my current test case, which uses -Wc++-compat... unfortunately it still fails. Test code: extern void xfer (int, int, unsigned char *); void call (int x, int y, void *arg) { xfer (x, y, arg); } barimba. gcc --syntax-only -Wc++-compat /tmp/r.c /tmp/r.c: In function ‘call’: /tmp/r.c:5:3: warning: request for implicit conversion from ‘void *’ to ‘unsigned char *’ not permitted in C++ [-Wc++-compat] xfer (x, y, arg); ^ I think perhaps the problem is that the warning_at call in convert_for_assignment that emits this warning should use expr_loc rather than 'location'. I haven't tested this theory.