[Bug c++/106567] [13 Regression] An array with a dependent type and initializer-deduced bound is treated as an array of unknown bound when captured in a lambda
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Sep 12 17:50:52 GMT 2022
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106567
--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jason Merrill <jason@gcc.gnu.org>:
https://gcc.gnu.org/g:7c989a8ed47228bdd494a2f0d1f6fdd325f953d7
commit r13-2628-g7c989a8ed47228bdd494a2f0d1f6fdd325f953d7
Author: Jason Merrill <jason@redhat.com>
Date: Mon Sep 12 12:59:46 2022 -0400
c++: lambda capture of array with deduced bounds [PR106567]
We can't use the type of an array variable directly if we haven't deduced
its length yet.
PR c++/106567
gcc/cp/ChangeLog:
* lambda.cc (type_deducible_expression_p): Check
array_of_unknown_bound_p.
gcc/testsuite/ChangeLog:
* g++.dg/cpp0x/lambda/lambda-array4.C: New test.
More information about the Gcc-bugs
mailing list