Skip to content
Snippets Groups Projects
Commit bd9b262f authored by Marek Polacek's avatar Marek Polacek
Browse files

c++: Fix error-recovery with requires expression [PR99500]

This fixes an ICE on invalid code where one of the parameters was
error_mark_node and thus resetting its DECL_CONTEXT crashed.

gcc/cp/ChangeLog:

	PR c++/99500
	* parser.c (cp_parser_requirement_parameter_list): Handle
	error_mark_node.

gcc/testsuite/ChangeLog:

	PR c++/99500
	* g++.dg/cpp2a/concepts-err3.C: New test.
parent 96ccb325
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