OSDN Git Service

PR c++/43787
[pf3gnuchains/gcc-fork.git] / gcc / cp / call.c
index 157b473..0ba0994 100644 (file)
@@ -5778,20 +5778,8 @@ build_over_call (struct z_candidate *cand, int flags, tsubst_flags_t complain)
        {
          tree to = stabilize_reference (cp_build_indirect_ref (fa, RO_NULL,
                                                                complain));
-         tree type = TREE_TYPE (to);
 
-         if (TREE_CODE (arg) != TARGET_EXPR
-             && TREE_CODE (arg) != AGGR_INIT_EXPR
-             && is_really_empty_class (type))
-           {
-             /* Avoid copying empty classes.  */
-             val = build2 (COMPOUND_EXPR, void_type_node, to, arg);
-             TREE_NO_WARNING (val) = 1;
-             val = build2 (COMPOUND_EXPR, type, val, to);
-             TREE_NO_WARNING (val) = 1;
-           }
-         else
-           val = build2 (INIT_EXPR, DECL_CONTEXT (fn), to, arg);
+         val = build2 (INIT_EXPR, DECL_CONTEXT (fn), to, arg);
          return val;
        }
     }