On Wed, Jul 13, 2011 at 08:20:58PM -0000, Ted Kremenek wrote: > Author: kremenek > Date: Wed Jul 13 15:20:58 2011 > New Revision: 135075 > > URL: http://llvm.org/viewvc/llvm-project?rev=135075&view=rev > Log: > format string checking: long and int have the same widths on 32-bit, so we > shouldn't warn about using > an "int" format specifier with a "long" type in 32-bit.
I don't like this change. I can think of the following cases for why this warning is triggered and useful: (1) Mismatch between PRI* and (s)size_t / ptrdiff_t definitions. This was a real issue on PPC for FreeBSD and NetBSD. (2) Size assumptions about (u)int32_t and it getting defined as long. (3) Code that breaks on 64bit builds or uses different #if branches in that case. This still sounds like a valid bug. So I thing it should be reverted. Joerg _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
