This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Incorrect warning about printf %0<fieldwidth>p format
Jim Avera <jima@cadence.com> writes:
> It actually says (and I think this is clear):
> "If a precision is given with a numeric conversion
> (d, i, o, u, x, and X), the 0 flag is ignored. For
> other conversions, the behavior is undefined."
>
> We are not talking about *precision*, but *min field width*.
No, we're not. We're talking about the '0' flag. The warning says:
warning: `0' flag used with `%p' printf format
And from the paragraph I quoted it is clear the the '0' flag is indeed
not valid for a 'p' conversion.
--
Falk