varasm.c (mergeable_string_section): Check for embedded NULs and NUL termination...
authorJakub Jelinek <jakub@redhat.com>
Wed, 21 Jun 2006 08:58:44 +0000 (10:58 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Wed, 21 Jun 2006 08:58:44 +0000 (10:58 +0200)
commit0841534abdf8bd06c42c5ae0293fb01d25b3e7b3
treefd1af8dab866ad596acc77b89185aabb10394617
parent470f18fcaa9522d1488158cc369250d38915ed1c
varasm.c (mergeable_string_section): Check for embedded NULs and NUL termination in the first int_size_in_bytes...

* varasm.c (mergeable_string_section): Check for embedded NULs and
NUL termination in the first int_size_in_bytes (TREE_TYPE (decl))
rather than TREE_STRING_LENGTH bytes.

* gcc.dg/merge-all-constants-1.c: New test.

From-SVN: r114842
gcc/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/merge-all-constants-1.c [new file with mode: 0644]
gcc/varasm.c