This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Unreviewed patch for diagnostic format checking
"Kaveh R. Ghazi" <ghazi@caip.rutgers.edu> writes:
| Gaby - if you'd like to take a look and are not familiar with the
| format checking data tables, you can verify things are setup correctly
| by cross-referencing the testcase.
I was not familiar with the format checking machinery and was trying
to understand the bits.
I believe you'll uncomment
+/* FIXME: the %ll and %w modifiers are expected to be added "soon". */
+#if 0
+ { "l", FMT_LEN_l, STD_C89, "ll", FMT_LEN_ll, STD_C89 },
+ { "w", FMT_LEN_none, STD_C89, NULL, 0, 0 },
+#endif
I don't understand this:
+ { 'p', 0, 0, N_("precision"), N_("precision in printf format"), STD_C89 },
%p in the diagnostic framework is for pointer (void *).
Same for :
+ { 'L', 0, 0, N_("length modifier"), N_("length modifier in printf format"), STD_C89 },
the C++ front-end uses it for the language specified in an
extern-language linkage specification. And for consistency, that
should be the same for the C front-end.
+ /* %H will require "location_t" at runtime. */
%H actually requires a 'location_t *'.
Thanks for any clarifications.
-- Gaby