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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [pr48660.C] - Blame information for rev 693

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
template struct val { char a[N]; };
2
 
3
class Base
4
{
5
public:
6
  virtual val<1> get1() const = 0;
7
  virtual val<2> get2() const = 0;
8
  virtual val<3> get3() const = 0;
9
  virtual val<4> get4() const = 0;
10
};
11
 
12
class Derived : public virtual Base
13
{
14
public:
15
  virtual val<1> get1() const { return foo->get1(); }
16
  virtual val<2> get2() const { return foo->get2(); }
17
  virtual val<3> get3() const { return foo->get3(); }
18
  virtual val<4> get4() const { return foo->get4(); }
19
  Base *foo;
20
};
21
 
22
Base* make() { return new Derived; }

powered by: WebSVN 2.1.0

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