https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102626
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Slightly reduced:
template <typename T, auto ...ms> struct P;
template <typename S, typename ...Ts, Ts S::* ...ms>
struct P<S, ms...> {
static constexpr int size() { return (sizeof(S{}.*ms) + ...); }
int sz;
P() : sz(size()) {}
};
struct A { int x, y; };
auto p = P<A, &A::x, &A::y>();