From 61e215dd1f4d56583102a08cd2b9c0533caed3ac Mon Sep 17 00:00:00 2001 From: Richard Stallman Date: Sat, 31 Jul 1993 20:13:36 +0000 Subject: [PATCH] (process_init_element): Treat string constants specially only for arrays of integers. From-SVN: r5048 --- gcc/c-typeck.c | 1 + 1 file changed, 1 insertion(+) diff --git a/gcc/c-typeck.c b/gcc/c-typeck.c index 2e0d0f6..9f2a8bc 100644 --- a/gcc/c-typeck.c +++ b/gcc/c-typeck.c @@ -6005,6 +6005,7 @@ process_init_element (value) char x[] = {"foo"}; */ if (string_flag && TREE_CODE (constructor_type) == ARRAY_TYPE + && TREE_CODE (TREE_TYPE (constructor_type)) == INTEGER_TYPE && integer_zerop (constructor_unfilled_index)) { constructor_stack->replacement_value = value; -- 2.7.4