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

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-dev/] [fsf-gcc-snapshot-1-mar-12/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [cpp0x/] [regress/] [abi-empty7.C] - Blame information for rev 783

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// Copy of abi/empty7.C.
2
// { dg-do run { target i?86-*-* x86_64-*-* } }
3
// { dg-require-effective-target ilp32 }
4
// { dg-options "-fabi-version=0 -std=c++0x" }
5
 
6
struct S1 {};
7
struct S2 { virtual void f () {} S1 s1[4]; };
8
struct S3 : virtual public S2 {};
9
struct S4 : virtual public S2 { int i; };
10
struct S5 : public S3, virtual public S4 {};
11
struct S6 { S5 s5; };
12
struct S7 { S1 s1[5]; };
13
struct S8 : public S1, public S6, virtual public S7 { };
14
 
15
S8 s8;
16
 
17
int main () {
18
  if ((char *)(S7 *)&s8 - (char *)&s8 != 24)
19
    return 1;
20
}

powered by: WebSVN 2.1.0

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