OSDN Git Service

PR c++/53549
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / template / non-dependent11.C
1 // { dg-do compile }
2
3 // Origin: Jakub Jelinek <jakub@gcc.gnu.org>
4 //         Wolfgang Bangerth <bangerth@ticam.utexas.edu>
5
6 // PR c++/19311: Non-dependent address to member as function argument.
7
8 template <class R, class T>          void foo (R (T::*x) ()); 
9 template <class R, class T, class C> void foo (R (T::*x) (C)); 
10  
11 template<int> struct I { 
12   int o (); 
13   int o () const; 
14 }; 
15  
16 template <int> void bar (void) { 
17   foo <int, I<1> > (&I<1>::o); 
18 }