c++: tweak resolve_args change
authorJason Merrill <jason@redhat.com>
Fri, 1 Jul 2022 04:37:10 +0000 (00:37 -0400)
committerJason Merrill <jason@redhat.com>
Fri, 1 Jul 2022 14:55:35 +0000 (10:55 -0400)
I don't know why I used tf_error instead of complain here.

PR c++/105779

gcc/cp/ChangeLog:

* call.cc (resolve_args): Use complain.

gcc/cp/call.cc

index 45253b1..726770d 100644 (file)
@@ -4675,7 +4675,7 @@ resolve_args (vec<tree, va_gc> *args, tsubst_flags_t complain)
 
       /* Force auto deduction now.  Omit tf_warning to avoid redundant
         deprecated warning on deprecated-14.C.  */
-      if (!mark_single_function (arg, tf_error))
+      if (!mark_single_function (arg, complain & ~tf_warning))
        return NULL;
     }
   return args;