1// RUN: %clang_cc1 -fsyntax-only %s -verify
2// expected-no-diagnostics
3
4namespace rdar10544564 {
5  // Check that we don't attempt to use an overloaded operator& when
6  // naming a pointer-to-member.
7  struct X {
8    void** operator & ();
9  };
10
11  struct Y
12  {
13  public:
14    X member;
15    X memfunc1();
16    X memfunc2();
17    X memfunc2(int);
18
19    void test() {
20      X Y::*data_mem_ptr = &Y::member;
21      X (Y::*func_mem_ptr1)() = &Y::memfunc1;
22      X (Y::*func_mem_ptr2)() = &Y::memfunc2;
23    }
24  };
25
26  X Y::*data_mem_ptr = &Y::member;
27  X (Y::*func_mem_ptr1)() = &Y::memfunc1;
28  X (Y::*func_mem_ptr2)() = &Y::memfunc2;
29}
30