Debian Codegraph @

gcc/testsuite/g++.dg/cpp1y/lambda-generic-const2.C

raw
1 // PR c++/67411
2 // { dg-do compile { target c++14 } }
3
4 template <class T>
5 void f()
6 {
7 int i = 42;
8 [=] {
9 const int x = i;
10 [&](auto) {
11 [=] { return x; }();
12 }(1);
13 }();
14 }
15
16 int main()
17 {
18 f<int>();
19 }