This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/20103] [4.0/4.1 regression] ICE in create_tmp_var with C99 style struct initializer
- From: "giovannibajo at libero dot it" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Mar 2005 08:51:28 -0000
- Subject: [Bug c++/20103] [4.0/4.1 regression] ICE in create_tmp_var with C99 style struct initializer
- References: <20050220111234.20103.falk@debian.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From giovannibajo at libero dot it 2005-03-07 08:51 -------
(In reply to comment #15)
> + case TARGET_EXPR:
> + {
> + tree r = tsubst_copy (t, args, complain, in_decl);
> +
> + TREE_TYPE (r) = RECUR (TREE_TYPE (t));
> + TARGET_EXPR_SLOT (r) = RECUR (TARGET_EXPR_SLOT (t));
> + TARGET_EXPR_INITIAL (r) = RECUR (TARGET_EXPR_INITIAL (t));
> + TARGET_EXPR_CLEANUP (r) = RECUR (TARGET_EXPR_CLEANUP (t));
> +
> + if (TREE_TYPE (TARGET_EXPR_SLOT (t))
> + == TREE_TYPE (TARGET_EXPR_INITIAL (t)))
> + TREE_TYPE (TARGET_EXPR_SLOT (r)) =
> + TREE_TYPE (TARGET_EXPR_INITIAL (r));
> +
> + if (TREE_TYPE (t) == TREE_TYPE (TARGET_EXPR_SLOT (t)))
> + TREE_TYPE (r) = TREE_TYPE (TARGET_EXPR_SLOT (r));
> +
> + return r;
> + }
> +
Can you add a comment that TARGET_EXPR is being used to represent C99 compound
literals?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20103