]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - gcc/cp/constexpr.cc
c++: P0847R7 (deducing this) - prerequisite changes. [PR102609]
[thirdparty/gcc.git] / gcc / cp / constexpr.cc
index 37500b7ea7a5a4fa9785f104c1194d9ecfee2f2b..6350fe1540856ade686cec72bfa7cf1a61165d08 100644 (file)
@@ -291,7 +291,7 @@ is_valid_constexpr_fn (tree fun, bool complain)
 
       /* C++14 DR 1684 removed this restriction.  */
       if (cxx_dialect < cxx14
-         && DECL_NONSTATIC_MEMBER_FUNCTION_P (fun)
+         && DECL_IOBJ_MEMBER_FUNCTION_P (fun)
          && !CLASSTYPE_LITERAL_P (DECL_CONTEXT (fun)))
        {
          ret = false;
@@ -1886,7 +1886,7 @@ cxx_bind_parameters_in_call (const constexpr_ctx *ctx, tree t, tree fun,
                                          non_constant_p, overflow_p);
       /* Check we aren't dereferencing a null pointer when calling a non-static
         member function, which is undefined behaviour.  */
-      if (i == 0 && DECL_NONSTATIC_MEMBER_FUNCTION_P (fun)
+      if (i == 0 && DECL_OBJECT_MEMBER_FUNCTION_P (fun)
          && integer_zerop (arg)
          /* But ignore calls from within compiler-generated code, to handle
             cases like lambda function pointer conversion operator thunks