re PR c/89061 (GCC 9 introduces false positive in -Wjump-misses-init)
authorJakub Jelinek <jakub@redhat.com>
Wed, 30 Jan 2019 07:49:58 +0000 (08:49 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Wed, 30 Jan 2019 07:49:58 +0000 (08:49 +0100)
commitfe509359cf5ff58edd84bb1f28323af6dc4dd4b4
tree8b48e406dd9b023b4e99192f8c9d245457c2b4fe
parent2ab6839bccb22a04c6df2000858c36d0ffa313ce
re PR c/89061 (GCC 9 introduces false positive in -Wjump-misses-init)

PR c/89061
* c-tree.h (C_DECL_COMPOUND_LITERAL_P): Define.
* c-decl.c (decl_jump_unsafe): Return false for
C_DECL_COMPOUND_LITERAL_P decls.
(build_compound_literal): Set C_DECL_COMPOUND_LITERAL_P.

* gcc.dg/pr89061.c: New test.

From-SVN: r268381
gcc/c/ChangeLog
gcc/c/c-decl.c
gcc/c/c-tree.h
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pr89061.c [new file with mode: 0644]