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

Subversion Repositories scarts

[/] [scarts/] [trunk/] [toolchain/] [scarts-gcc/] [gcc-4.1.1/] [gcc/] [testsuite/] [g++.dg/] [template/] [friend3.C] - Rev 12

Compare with Previous | Blame | View Log

// { dg-do compile }

// Copyright (C) 2001 Free Software Foundation, Inc.
// Contributed by Nathan Sidwell 28 Dec 2001 <nathan@codesourcery.com>

// PR 775 friend classes with qualified names inside template classes.

struct A
{
  struct B {
    B () { }
  };
};

template <class T>
struct C: A {
  friend A::B::B (); // 2.95.2 ICE
  friend struct A;
  friend struct A::B; // 2.97 error
};

template class C<char>;

template <typename T> class TPL
{
  class nested;
};

template <typename T> class TPL<T>::nested 
{
};

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.