Michael Lotz a84f174425 Bring GCC 4.3.3 to trunk.
git-svn-id: file:///srv/svn/repos/haiku/buildtools/trunk@29033 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-01-26 05:03:14 +00:00

27 lines
396 B
C

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main ()
{
struct a {
int x;
int y;
char z;
};
struct b {
int x;
int y;
};
struct b k;
(*((volatile struct a *) &k)).z = 'q';
return 0;
}
/* { dg-output "mudflap violation 1..check/write.*" } */
/* { dg-output "Nearby object 1.*" } */
/* { dg-output "mudflap object.*.main. k.*" } */
/* { dg-do run { xfail *-*-* } } */