OSDN Git Service
(root)
/
pf3gnuchains
/
gcc-fork.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
cp:
[pf3gnuchains/gcc-fork.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.pt
/
typename19.C
1
// Special g++ Options:
2
// Origin: Mark Mitchell <mark@codesourcery.com>
3
4
template <class T>
5
struct O {
6
typedef char X;
7
};
8
9
template <class T>
10
struct S {
11
typedef double X;
12
13
template <class U>
14
struct I : public O<U> {
15
static X x; // WARNING - lookup finds S<T>::X
16
};
17
};
18
19
template <class T>
20
template <class U>
21
typename S<T>::X S<T>::I<U>::x;
22
23
int main()
24
{
25
return sizeof (S<int>::I<double>::x) == 1;
26
}