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

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc1/] [gcc/] [testsuite/] [g++.old-deja/] [g++.jason/] [friend.C] - Blame information for rev 305

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

Line No. Rev Author Line
1 305 jeremybenn
// { dg-do run  }
2
// Bug: g++ doesn't keep track of the lexical context of friends properly.
3
 
4
extern "C" void exit(int);
5
 
6
struct B;
7
struct A {
8
  static void f () { exit (1); }
9
};
10
 
11
struct B {
12
  static void f () { exit (0); }
13
  friend void g (B) { f (); }
14
};
15
 
16
int main ()
17
{
18
  B b;
19
  g (b);
20
}

powered by: WebSVN 2.1.0

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