]> git.ipfire.org Git - thirdparty/gcc.git/commit
c++: variadic ttp constraint subsumption [PR99904]
authorPatrick Palka <ppalka@redhat.com>
Thu, 7 Oct 2021 14:02:54 +0000 (10:02 -0400)
committerPatrick Palka <ppalka@redhat.com>
Thu, 7 Oct 2021 14:04:52 +0000 (10:04 -0400)
commit052b2df6f0ecd1e5b55056911b16bca8b31ef7df
treeb2804eb06f52a488e778c7624fd8b815dac7ed4e
parent04b814c26052b6fb83b7067679fc67c1a129335e
c++: variadic ttp constraint subsumption [PR99904]

Here we're crashing when level-lowering the variadic constraint C<Ts...>
on the template template parameter TT because tsubst_pack_expansion expects
processing_template_decl to be set during a partial substitution.

PR c++/99904

gcc/cp/ChangeLog:

* pt.c (is_compatible_template_arg): Set processing_template_decl
around tsubst_constraint_info.

gcc/testsuite/ChangeLog:

* g++.dg/cpp2a/concepts-ttp4.C: New test.

(cherry picked from commit 2e6e0d86a06389056d0e7fecc99c547420ad787a)
gcc/cp/pt.c
gcc/testsuite/g++.dg/cpp2a/concepts-ttp4.C [new file with mode: 0644]