| 1 |
// { dg-additional-options "-dA -std=gnu++17 -gdwarf-4 -O1 -fdebug-types-section" } |
| 2 |
// reject .pseudo label, but "label" is ok. |
| 3 |
// { dg-final { scan-assembler-not "\[^L\"\]_ZN5Test18testFuncEv" } } |
| 4 |
// undefined ref to _ZN5Test18testFuncEv |
| 5 |
|
| 6 |
class Test1 { |
| 7 |
public: |
| 8 |
static int testFunc() { return 1; } |
| 9 |
}; |
| 10 |
|
| 11 |
template <typename T, |
| 12 |
T (*funcImpl)()> |
| 13 |
class TestWrapper { |
| 14 |
public: |
| 15 |
static T func() __attribute((noinline)) { return (*funcImpl)(); } |
| 16 |
}; |
| 17 |
|
| 18 |
int main() { |
| 19 |
return TestWrapper<int, &Test1::testFunc>::func(); |
| 20 |
} |