repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
/cp
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
cpp1y
/
lambda-generic-static2.C
blob
c8e251fc957131b9492418300b3e52e33398c844
1
// PR c++/70735
2
// { dg-do run { target c++14 } }
3
4
template <class T>
5
static void g()
6
{
7
static int a;
8
auto f = [](auto) { return a; };
9
if (f(0) != 0)
10
__builtin_abort();
11
a = 1;
12
if (f(0) != 1)
13
__builtin_abort();
14
}
15
16
int main()
17
{
18
g<int>();
19
}