re PR c/5105 (compound literal patch broken with inlining)
authorJoseph Myers <jsm28@cam.ac.uk>
Mon, 17 Dec 2001 01:18:41 +0000 (01:18 +0000)
committerJoseph Myers <jsm28@gcc.gnu.org>
Mon, 17 Dec 2001 01:18:41 +0000 (01:18 +0000)
commit8d37a5c0db11afb1c4b6d578ad46d1dfb1213118
treeb0c444fe54bd3f1b332cc67c0727beaa08189268
parentcf6ede82ac9bf9fdd08be25e806e131ac9a8f47e
re PR c/5105 (compound literal patch broken with inlining)

* c-common.def (COMPOUND_LITERAL_EXPR): Contain a DECL_STMT, not
a DECL directly.
* c-common.h (COMPOUND_LITERAL_EXPR_DECL_STMT): New.
(COMPOUND_LITERAL_EXPR_DECL): Adjust definition.
* c-decl.c (build_compound_literal): Put the decl inside a
DECL_STMT.
* doc/c-tree.texi (COMPOUND_LITERAL_EXPR): Update documentation.
Fixes PR c/5105.

testsuite:
* gcc.c-torture/compile/20011217-1.c: New test.

From-SVN: r48085
gcc/ChangeLog
gcc/c-common.def
gcc/c-common.h
gcc/c-decl.c
gcc/doc/c-tree.texi
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/compile/20011217-1.c [new file with mode: 0644]