p4.cpp revision fc55a8290a3e81111c0a373e1a04b09dd7da0b98
1// RUN: %clang_cc1 -fsyntax-only -verify %s
2
3namespace PR8598 {
4  template<class T> struct identity { typedef T type; };
5
6  template<class T, class C>
7  void f(T C::*, typename identity<T>::type*){}
8
9  struct X { void f() {}; };
10
11  void g() { (f)(&X::f, 0); }
12}
13
14namespace PR12132 {
15  template<typename S> void fun(const int* const S::* member) {}
16  struct A { int* x; };
17  void foo() {
18    fun(&A::x);
19  }
20}
21