mirror of git://gcc.gnu.org/git/gcc.git
parent
423f265c70
commit
8af43d55cd
|
@ -0,0 +1,31 @@
|
|||
// Special g++ Options:
|
||||
// execution test - XFAIL *-*-*
|
||||
// excess errors test - XFAIL *-*-*
|
||||
|
||||
int i = 0;
|
||||
|
||||
template <class T>
|
||||
struct S {
|
||||
struct X {};
|
||||
};
|
||||
|
||||
template <class T>
|
||||
void f(T)
|
||||
{
|
||||
S<T>::X();
|
||||
}
|
||||
|
||||
template <>
|
||||
struct S<int> {
|
||||
static void X() { i = 1; }
|
||||
};
|
||||
|
||||
int main()
|
||||
{
|
||||
f(3);
|
||||
if (i != 1)
|
||||
return 1;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue