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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [g++.old-deja/] [g++.other/] [lookup15.C] - Rev 816

Compare with Previous | Blame | View Log

// { dg-do assemble  }
// Origin: Benjamin Kosnik <bkoz@cygnus.com>

class b
{
  int j;
public:
  b(int a = 6): j(a) {}
  void imbue(int a) {++j;}
};

class d: public b
{
  int k;
public:
  d(int a = 7): b(a), k(a) {}
  void imbue(int a) {++k;}
};
  
//virtual public kills, public ok
class mostd: virtual public d
{
  int l;
public:
  mostd(int a = 9): d(a), l(a) {}
};

int main() {

  d dobj;
  dobj.imbue(5);

  mostd mobj;
  mobj.imbue(5);
  
  return 0;
}

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.