aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.8.1/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-mixed.C
blob: ed0565fa9ce9b33b22f93d20e868c83b45787ee3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// { dg-do run }
// { dg-options "-std=c++0x" }
#include <cassert>

int main() {
  int i = 1, j = 2;
  [&i, j] () mutable -> void { i = 0; j = 0; } ();
  assert(i == 0);
  assert(j == 2);

  return 0;
}