OSDN Git Service

PR c++/47705
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / template / inherit4.C
1 // PR c++/21008, DR 515
2
3 struct A {
4   int foo_;
5 };
6 template <typename T> struct B: public A { };
7 template <typename T> struct C: B<T> {
8   int foo() {
9     return A::foo_;  // #1
10   }
11 };
12 int f(C<int>* p) {
13   return p->foo();
14 }