// PR c++/48647 // { dg-options -std=c++0x } template< class T > T&& declval(); template< class T, class U > decltype( true ? declval() : declval() ) test( int ); template< class T, class U > void test( ... ); template< class T, class U > struct is_same { static const bool value = false; }; template< class T > struct is_same { static const bool value = true; }; #define SA(X) static_assert ((X),#X) typedef decltype( test(0) ) void_expected; SA ((is_same::value)); SA ((!is_same::value));