diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index b1c0befdd3d460624ee1f0ac7650478e68f5a6b6..d02cd056827bba8ef69373951e4be2933dd2bf4e 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,8 @@
 2004-06-24  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
 
+	PR/16131
+	* gimplify.c (voidify_wrapper_expr): Allow TARGET_EXPR.
+
 	* gimplify.c: Remove unneeded forward declarations.
 
 	* gimplify.c (append_to_compound_expr): Deleted.
diff --git a/gcc/gimplify.c b/gcc/gimplify.c
index 7d1b71544a459bccfd80a6e532b0e8fb7e5eb609..b482fface7d35db4bc1cdc70eeac32493f30715c 100644
--- a/gcc/gimplify.c
+++ b/gcc/gimplify.c
@@ -828,7 +828,8 @@ voidify_wrapper_expr (tree wrapper, tree temp)
 	  goto restart;
 	}
       /* The C++ frontend already did this for us.  */
-      else if (TREE_CODE (*p) == INIT_EXPR)
+      else if (TREE_CODE (*p) == INIT_EXPR
+	       || TREE_CODE (*p) == TARGET_EXPR)
 	temp = TREE_OPERAND (*p, 0);
       /* If we're returning a dereference, move the dereference
 	 outside the wrapper.  */