re PR c++/79133 (lambda capture shadowing parameter & decltype confusion)
authorVille Voutilainen <ville.voutilainen@gmail.com>
Tue, 7 Aug 2018 13:46:16 +0000 (16:46 +0300)
committerVille Voutilainen <ville@gcc.gnu.org>
Tue, 7 Aug 2018 13:46:16 +0000 (16:46 +0300)
commit63b48839b8e19a33bb2b0f86e1a443c53b395bc0
tree9e8a087ee849a02f9143bf2caa45d45d81af9bb9
parent806562fd6269a3d7e0651d5bbf9085c7708fb5cd
re PR c++/79133 (lambda capture shadowing parameter & decltype confusion)

PR c++/79133

gcc/cp/

PR c++/79133
* name-lookup.c (check_local_shadow): Reject captures and parameters
with the same name.

testsuite/

PR c++/79133
* g++.dg/cpp0x/lambda/lambda-shadow3.C: New.
* g++.dg/cpp1y/lambda-generic-variadic18.C: Likewise.

From-SVN: r263357
gcc/cp/ChangeLog
gcc/cp/name-lookup.c
gcc/testsuite/g++.dg/cpp0x/lambda/lambda-shadow3.C [new file with mode: 0644]
gcc/testsuite/g++.dg/cpp1y/lambda-generic-variadic18.C [new file with mode: 0644]