OSDN Git Service

Add NIOS2 support. Code from SourceyG++.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / cpp0x / lambda / lambda-copy-neg.C
1 // { dg-options "-std=c++0x" }
2
3 int main() {
4   int i;
5   const char* s;
6   [i, s] () -> void { 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