[PATCH] fix outstanding -Wformat-length failures (pr77735 et al.)

Martin Sebor msebor@gmail.com
Sun Oct 2 20:10:00 GMT 2016


The attached patch fixes a number of outstanding test failures
and ILP32-related bugs in the gimple-ssa-sprintf pattch pointed
out in bug 77676 and 77735).  The patch also fixes c_strlen to
correctly handle wide strings (previously it accepted them but
treated them as nul-terminated byte sequences), and adjusts the
handling of "%a" to avoid assuming a specific number of decimal
digits (this is likely a defect in C11 that I'm pursuing with
WG14).

Tested on powerpc64le, i386, and x86_64.

There is one outstanding failure in the builtin-sprintf-warn-1.c
test on powerpc64le that looks like it might be due to the
printf_pointer_format target hook not having been set up entirely
correctly.  I'll look into that separately, along with pr77819.

Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc-77735.diff
Type: text/x-patch
Size: 58014 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20161002/b756297d/attachment.bin>


More information about the Gcc-patches mailing list