Fix test-suite fallout of default -Wreturn-type.
[official-gcc.git] / gcc / testsuite / g++.dg / cpp0x / lambda / lambda-template2.C
blob8fbb821a4d3fc066c0828dea75f5f55dd7c44e91
1 // PR c++/47049
2 // { dg-do compile { target c++11 } }
4 enum { E = 0, F = 1 };
5 template <int N, int M = ((N == 1) ? F : E)> class S {};
6 template <int N>
7 struct T
9   static void
10   foo (S<N> *p)
11   {
12     S<N> u;
13     [&u] ()->bool { return true; } ();
14   }
17 int main()
19   T<0>().foo(0);