1 // RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++11 2 3 struct A {}; 4 5 struct B { 6 operator A*(); 7 }; 8 9 struct C : B { 10 11 }; 12 13 foo(C c,B b,int A::* pmf)14void foo(C c, B b, int A::* pmf) { 15 int j = c->*pmf; 16 int i = b->*pmf; 17 } 18 19 struct D { 20 operator const D *(); 21 }; 22 23 struct DPtr { 24 operator volatile int D::*(); 25 }; 26 test(D d,DPtr dptr)27int test(D d, DPtr dptr) { 28 return d->*dptr; 29 } 30 31