]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - gcc/cp/decl.c
class.c (check_bases): Propagate non-literality.
[thirdparty/gcc.git] / gcc / cp / decl.c
index e513bc08c6a3d0a6f93315e9f85333091dcf2deb..e27a64d8170a04b37718fa10034e6de12653596d 100644 (file)
@@ -10292,6 +10292,10 @@ grok_special_member_properties (tree decl)
        TYPE_HAS_COMPLEX_MOVE_CTOR (class_type) = 1;
       else if (is_list_ctor (decl))
        TYPE_HAS_LIST_CTOR (class_type) = 1;
+
+      if (DECL_DECLARED_CONSTEXPR_P (decl)
+         && !copy_fn_p (decl) && !move_fn_p (decl))
+       TYPE_HAS_CONSTEXPR_CTOR (class_type) = 1;
     }
   else if (DECL_OVERLOADED_OPERATOR_P (decl) == NOP_EXPR)
     {