summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/other/ptrmem6.C
blob: 5fe796e1c0492cfcd5107df285d1aae104f14899 (plain)
1
2
3
4
5
6
7
8
9
10
// PR c++/19666
// Origin: Volker Reichelt <reichelt@gcc.gnu.org>
// { dg-do compile }

struct A { int i; };

int foo (A *p)
{
  return &p->i - &(p->*&A::i);
}