OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [template/] [typedef20.C] - Rev 696

Go to most recent revision | Compare with Previous | Blame | View Log

// Contributed by Dodji Seketeli <dodji@redhat.com>
// Origin PR c++/40007
// { dg-do compile }

class x
{
  typedef int privtype; // { dg-error "is private" }

protected:
  typedef int type;
};

template<typename T>
struct y : public x
{
  typename x::type z;
};

template<typename T>
struct y<T*> : public x
{
  typedef x::type good;
  typedef x::privtype bad; // { dg-error "within this context" }
};

template class y<int>;
template class y<int*>;

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.