[Bug c/84953] [6/7 Regression] misleading warning from strpbrk(x,"")
jakub at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Jun 22 20:53:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84953
--- Comment #10 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Fri Jun 22 20:52:44 2018
New Revision: 261931
URL: https://gcc.gnu.org/viewcvs?rev=261931&root=gcc&view=rev
Log:
Backported from mainline
2018-03-20 Jakub Jelinek <jakub@redhat.com>
PR c/84953
* builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
instead of TREE_TYPE (s1) for the return value.
* gcc.dg/pr84953.c: New test.
Added:
branches/gcc-7-branch/gcc/testsuite/gcc.dg/pr84953.c
Modified:
branches/gcc-7-branch/gcc/ChangeLog
branches/gcc-7-branch/gcc/builtins.c
branches/gcc-7-branch/gcc/testsuite/ChangeLog
More information about the Gcc-bugs
mailing list