Skip to content
Snippets Groups Projects
Commit 41fd9d26 authored by Patrick Palka's avatar Patrick Palka
Browse files

c++: constraints and address of template-id

When resolving the address of a template-id, we need to drop functions
whose associated constraints are not satisfied, as per [over.over].  We
do so in resolve_address_of_overloaded_function, but not in
resolve_overloaded_unification or resolve_nondeduced_context, which
seems like an oversight.

gcc/cp/ChangeLog:

	* pt.c (resolve_overloaded_unification): Drop functions with
	unsatisfied constraints.
	(resolve_nondeduced_context): Likewise.

gcc/testsuite/ChangeLog:

	* g++.dg/cpp2a/concepts-fn5.C: New test.
	* g++.dg/concepts/fn8.C: Generalize dg-error directive to accept
	"no matching function ..." diagnostic.
	* g++.dg/cpp2a/concepts-fn1.C: Likewise.
	* g++.dg/cpp2a/concepts-ts2.C: Likewise.
	* g++.dg/cpp2a/concepts-ts3.C: Likewise.
parent 90f7636b
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment