FreeBSD/contrib/gcc/cp/cp-gimplify.c
/* Gimplify initialization from an AGGR_INIT_EXPR.  */
Gimplify initialization from an AGGR_INIT_EXPR.
Gimplify initialization from an AGGR_INIT_EXPR .
static void
cp_gimplify_init_expr (tree *expr_p, tree *pre_p, tree *post_p)
{
  tree from = TREE_OPERAND (*expr_p, 1);
  tree to = TREE_OPERAND (*expr_p, 0);
  tree sub;
  if (TREE_CODE (from) == TARGET_EXPR)
    from = TARGET_EXPR_INITIAL (from);
  sub = expr_last (from);
  if (TREE_CODE (sub) == AGGR_INIT_EXPR)
    {
      gimplify_expr (&to, pre_p, post_p, is_gimple_lvalue, fb_lvalue);
      TREE_OPERAND (sub, 2) = to;
      *expr_p = from;
      if (from != sub)
	TREE_TYPE (from) = void_type_node;
    }
}
static void cp_gimplify_init_expr ( tree * expr_p , tree * pre_p , tree * post_p ) { tree from = TREE_OPERAND ( * expr_p , 1 ) ; tree to = TREE_OPERAND ( * expr_p , 0 ) ; tree sub ; if ( TREE_CODE ( from ) == TARGET_EXPR ) from = TARGET_EXPR_INITIAL ( from ) ; sub = expr_last ( from ) ; if ( TREE_CODE ( sub ) == AGGR_INIT_EXPR ) { gimplify_expr ( & to , pre_p , post_p , is_gimple_lvalue , fb_lvalue ) ; TREE_OPERAND ( sub , 2 ) = to ; * expr_p = from ; if ( from != sub ) TREE_TYPE ( from ) = void_type_node ; } }
Gimplify initialization from an AGGR_INIT_EXPR.
Gimplify initialization from an AGGR_INIT_EXPR .
/* What about code that pulls out the temp and uses it elsewhere?  I
     think that such code never uses the TARGET_EXPR as an initializer.  If
     I'm wrong, we'll abort because the temp won't have any RTL.  In that
     case, I guess we'll need to replace references somehow.  */ /* Look through any COMPOUND_EXPRs, since build_compound_expr pushes them
     inside the TARGET_EXPR.  */ /* If we are initializing from an AGGR_INIT_EXPR, drop the INIT_EXPR and
     replace the slot operand with our target.

     Should we add a target parm to gimplify_expr instead?  No, as in this
     case we want to replace the INIT_EXPR.  */ /* The initialization is now a side-effect, so the container can
	 become void.  */