// { dg-do compile } // { dg-options "-std=c++0x" } // Test overload preference char*/int template struct tType_equal; template struct tType_equal { typedef void type; }; template inline typename tType_equal::type type_equal(U) { } char* f( char* ); int f( int ); long int f( long int ); void test_f() { // Overloading cases // type_equal(f(nullptr)); type_equal(f(0)); decltype(nullptr) mynull = 0; type_equal(f(mynull)); }