URL
https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 149 |
Rev 154 |
// { dg-do assemble }
|
// { dg-do assemble }
|
|
|
// Copyright (C) 2001 Free Software Foundation, Inc.
|
// Copyright (C) 2001 Free Software Foundation, Inc.
|
// Contributed by Nathan Sidwell 12 Apr 2001
|
// Contributed by Nathan Sidwell 12 Apr 2001
|
|
|
// Check we deal with aligning virtual bases after a trailing empty
|
// Check we deal with aligning virtual bases after a trailing empty
|
// base class properly
|
// base class properly
|
|
|
struct A {};
|
struct A {};
|
struct B1 : A {};
|
struct B1 : A {};
|
struct B2 : A {};
|
struct B2 : A {};
|
struct B3 : A {};
|
struct B3 : A {};
|
|
|
struct C : B1, B2, virtual B3 {};
|
struct C : B1, B2, virtual B3 {};
|
|
|
int main ()
|
int main ()
|
{
|
{
|
#if defined (__GXX_ABI_VERSION) && __GXX_ABI_VERSION >= 100
|
#if defined (__GXX_ABI_VERSION) && __GXX_ABI_VERSION >= 100
|
C c;
|
C c;
|
if (((char *)static_cast (&c) - (char *)&c) % __alignof__ (C))
|
if (((char *)static_cast (&c) - (char *)&c) % __alignof__ (C))
|
return 1;
|
return 1;
|
#endif
|
#endif
|
return 0;
|
return 0;
|
}
|
}
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.