[Bug c/37648] Incorrect warning "flag ignored with precision" in printf
ciobi at inbox dot com
gcc-bugzilla@gcc.gnu.org
Mon Sep 29 14:31:00 GMT 2008
------- Comment #2 from ciobi at inbox dot com 2008-09-29 14:30 -------
Sorry. The reason I said that the '0' flag was not actually ignored was that I
was sure that without it the padding would be done with spaces rather than '0'.
I guess some time ago I was using a compiler where the only way to get
0-padding was with "%0.4d" ; "%.4d" produced space-padding and I'm not sure
what "%04d" did, but I'm pretty sure that it wasn't what I wanted. So that's
how I remembered that "it must be done". When reporting the "bug" I just
assumed that "%.4d" would use space padding, and I figured that the fact that I
was getting 0-padding from "%0.4d" was due to the use of 0, which now I see
that is not true.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37648
More information about the Gcc-bugs
mailing list