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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [cpp0x/] [union2.C] - Rev 715

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

// Positive test for C++0x unrestricted unions
// { dg-options -std=c++0x }

struct A
{
  A();
  A(const A&);
  ~A();
};

union B
{
  A a;
  B();
  B(const B&);
  ~B();
};

B b;
B b2(b);

struct C
{
  union
  {
    A a;
  };
  C();
  C(const C&);
  ~C();
};

C c;
C c2(c);

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.