1 // PR c++/99790 2 // { dg-do compile { target c++17 } } 3 4 struct A; 5 struct B { void (*fn) (A *); }; 6 template <typename T> 7 int foo (const T &); 8 struct A { int a; static constexpr B b{[] (A *n) { n->*&A::a = 2; }}; }; 9 int a = foo (A::b); 10