summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-conv.C
blob: 5409d5ca3884ea511ad418308b2942cfb6a60dfd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Test for conversion from stateless lambda to function pointer.

// { dg-options -std=c++0x }
// { dg-final { scan-assembler "weak\[^\n\r\]*_?_ZZ1fvENKUlvE_cvPFvvEEv" { target { ! { *-*-darwin* *-*-mingw* *-*-cygwin *-*-hpux10* } } } } }

inline void f()
{
  void (*pfn)() = []{};
}

int main()
{
  f();
}