From 72479e324313e8a68a534527f79e741f9a7df6fa Mon Sep 17 00:00:00 2001 From: Andrew Sutton Date: Wed, 27 Nov 2019 15:09:22 +0000 Subject: re PR c++/88395 (ICE: Segmentation fault signal terminated program cc1plus, with -std=c++2a -fconcepts) 2019-11-27 Andrew Sutton PR c++/88395 Prevent recursive satisfaction by adding requests to the instantiation stack. gcc/cp/ * constraint.cc (satisfy_declaration_constraints): Push tinst levels around satisfaction. gcc/testsuite/ * g++.dg/cpp2a/concepts-pr88395.C: New. * g++.dg/cpp2a/concepts-recursive-sat1.C: New. * g++.dg/cpp2a/concepts-recursive-sat2.C: New. * g++.dg/cpp2a/concepts-recursive-sat3.C: New. From-SVN: r278773 --- gcc/cp/constraint.cc | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gcc/cp/constraint.cc') diff --git a/gcc/cp/constraint.cc b/gcc/cp/constraint.cc index d29c33a..9967b1e 100644 --- a/gcc/cp/constraint.cc +++ b/gcc/cp/constraint.cc @@ -2648,9 +2648,11 @@ satisfy_declaration_constraints (tree t, subst_info info) tree result = boolean_true_node; if (norm) { + push_tinst_level (t); push_access_scope (t); result = satisfy_associated_constraints (norm, args, info); pop_access_scope (t); + pop_tinst_level (); } if (info.quiet ()) -- cgit v1.1