OSDN Git Service

2001-02-26 Jeffrey Oldham <oldham@codesourcery.com>
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / g++.pt / ttp11.C
1 template<class T> class D
2 {
3         public:
4                 int f();
5 };
6
7 template<class T> int D<T>::f()
8 {
9         return sizeof(T);
10 }
11
12 template<template<class> class D,class E> class C
13 {
14                 D<E> d;
15         public:
16                 int f() { return d.f(); }
17 };
18
19 int main()
20 {
21         C<D,int> c;
22         C<D,char> d;
23         c.f();
24         d.f();
25 }