------- Comment #2 from manu at gcc dot gnu dot org 2008-01-14 00:42 ------- Good catch!
Well, there is something weird going on $ cc1 -fdump-tree-original -O winit-self.c { int i = i; int i = i; return i; } $ cc1plus -fdump-tree-original -O winit-self.c { int i; int i; <<cleanup_point <<< Unknown tree: expr_stmt (void) (i = i) >>> >>; return <retval> = i; } The first problem is that C++ FE does not generate a DECL_EXPR but a BIND_EXPR, so it does not trigger the conditional in c-gimplify.c (c_gimplify_expr). My guess is that this have never worked in C++. So we can just delete this option from the C++ FE and convert this to an enhancement request. If none disagrees, I will submit a patch in the next days. -- manu at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |manu at gcc dot gnu dot org Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Keywords| |diagnostic Last reconfirmed|0000-00-00 00:00:00 |2008-01-14 00:42:56 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34772