PR c/80619 - bad fix-it hint for GCC %lu directive with int argument: %wu
authorMartin Sebor <msebor@redhat.com>
Tue, 13 Aug 2019 15:55:40 +0000 (15:55 +0000)
committerMartin Sebor <msebor@gcc.gnu.org>
Tue, 13 Aug 2019 15:55:40 +0000 (09:55 -0600)
commit51ad8481b8fe3d47aaa4494deace6153c353dec1
treea515e0e078bacaad2c48cb0859c79ac59b123a03
parent547d5d22e96b900907889a2b49f8c9b09b035dac
PR c/80619 - bad fix-it hint for GCC %lu directive with int argument: %wu

gcc/c-family/ChangeLog:

PR c/80619
* c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
(asm_fprintf_length_spec): Same.
* c-format.h (format_lengths): Add FMT_LEN_w.

gcc/testsuite/ChangeLog:

PR c/80619
* gcc.dg/format/pr80619.c: New test.

From-SVN: r274385
gcc/c-family/ChangeLog
gcc/c-family/c-format.c
gcc/c-family/c-format.h
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/format/pr80619.c [new file with mode: 0644]