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
Merged revisions 208012,208018-208019,208021,208023-208030,208033,208037,208040-20804...
[official-gcc.git]
/
main
/
gcc
/
testsuite
/
g++.dg
/
cpp0x
/
lambda
/
lambda-copy-default-neg.C
blob
91f5d621b0a612ff3115c0ee5fa1719f0ac2e063
1
// { dg-do compile { target c++11 } }
2
3
int main() {
4
int i;
5
const char* s;
6
[=] () -> void { i; s; i; s; } ();
7
8
[] () -> void { i; } (); // { dg-error "" "`i' is not captured" }
9
[1] () -> void {} (); // { dg-error "expected identifier" }
10
11
return 0;
12
}
13