gcc/testsuite/g++.dg/cpp0x/constexpr-pmf1.C
raw| 1 | // PR c++/77775 |
| 2 | // { dg-options "-fdump-tree-fre1 -O1" } |
| 3 | // { dg-final { scan-tree-dump "== viewAdded" "fre1" { target c++11 } } } |
| 4 | |
| 5 | namespace Sublime { |
| 6 | struct View; |
| 7 | struct AreaIndex; |
| 8 | struct Area { |
| 9 | void qt_static_metacall(); |
| 10 | void viewAdded(AreaIndex *, View *); |
| 11 | }; |
| 12 | } |
| 13 | void Sublime::Area::qt_static_metacall() { |
| 14 | typedef void (Area::*_t)(AreaIndex *, View *); |
| 15 | if (*reinterpret_cast<_t *>(1) == _t(&Area::viewAdded)) |
| 16 | __builtin_abort(); |
| 17 | } |