c++: SFINAE-unfriendly error on throwing pointer [PR112436]
On the heels of r14-8903, this patch adds further complain parameters so that we don't emit "invalid use of incomplete type" from inside a concept. PR c++/112436 gcc/cp/ChangeLog: * except.cc (expand_start_catch_block): Pass tf_warning_or_error to is_admissible_throw_operand_or_catch_parameter. (build_throw): Pass complain to is_admissible_throw_operand_or_catch_parameter. (complete_ptr_ref_or_void_ptr_p): Add a tsubst_flags_t parameter. Use it. Return bool. Call complete_type_or_maybe_complain instead of complete_type_or_else. (is_admissible_throw_operand_or_catch_parameter): Add a tsubst_flags_t parameter. Use it. Guard error calls. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/concepts-pr112436.C: New test.
Loading
Please register or sign in to comment