From 8fcef540f3a1600c26bc7dbebed9c6142f3da7e8 Mon Sep 17 00:00:00 2001 From: "Kaveh R. Ghazi" Date: Sat, 16 Jul 2005 14:34:37 +0000 Subject: [PATCH] c-typeck.c (digest_init): Call 'convert_for_assignment' before returning. * c-typeck.c (digest_init): Call 'convert_for_assignment' before returning. From-SVN: r102090 --- gcc/ChangeLog | 5 +++++ gcc/c-typeck.c | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index de6bad93aff..8b57b807621 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2005-07-16 Kaveh R. Ghazi + + * c-typeck.c (digest_init): Call 'convert_for_assignment' + before returning. + 2005-07-16 Jan Hubicka * cfg.c (update_bb_profile_for_threading): Fix profile updating. diff --git a/gcc/c-typeck.c b/gcc/c-typeck.c index ab72ceea120..907a4fcba07 100644 --- a/gcc/c-typeck.c +++ b/gcc/c-typeck.c @@ -4442,6 +4442,10 @@ digest_init (tree type, tree init, bool strict_string, int require_constant) inside_init = error_mark_node; } + /* Added to enable additional -Wmissing-format-attribute warnings. */ + if (TREE_CODE (TREE_TYPE (inside_init)) == POINTER_TYPE) + inside_init = convert_for_assignment (type, inside_init, ic_init, NULL_TREE, + NULL_TREE, 0); return inside_init; } -- 2.30.2