OSDN Git Service

* method.c (process_subob_fn): Make sure no_implicit_p is non-null
[pf3gnuchains/gcc-fork.git] / gcc / cp / method.c
index c46c372..c4947d1 100644 (file)
@@ -951,7 +951,7 @@ process_subob_fn (tree fn, bool move_p, tree *spec_p, bool *trivial_p,
 
   /* Core 1402: A non-trivial copy op suppresses the implicit
      declaration of the move ctor/op=.  */
-  if (move_p && !move_fn_p (fn) && !trivial_fn_p (fn))
+  if (no_implicit_p && move_p && !move_fn_p (fn) && !trivial_fn_p (fn))
     *no_implicit_p = true;
 
   if (constexpr_p && !DECL_DECLARED_CONSTEXPR_P (fn))