repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
FSF GCC merge 02/23/03
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.pt
/
memtemp100.C
blob
c88c3e7a2f56860c865c1b740f80ce78fbfe931b
1
// Build don't link:
2
// Origin: philippeb@videotron.ca
3
// Special g++ Options:
4
5
#include <iostream>
6
7
using namespace std;
8
9
template <class T> struct traits
10
{
11
typedef long next;
12
};
13
14
15
template <class T>
16
struct c1
17
{
18
template <class U>
19
struct c2
20
{
21
c2()
22
{
23
cout << __PRETTY_FUNCTION__ << endl;
24
}
25
};
26
};
27
28
29
template <class T>
30
void foo()
31
{
32
cout << __PRETTY_FUNCTION__ << endl;
33
typename c1<typename traits<T>::next>::template c2<void>();
34
}
35
36
37
int main()
38
{
39
foo<int>();
40
}