Merge from mainline
[official-gcc.git] / gcc / testsuite / consistency.vlad / layout / s-double-float.c
blob0dbbfef41cba48e948f309ee6046be03b5e70f5a
1 #include <stdio.h>
3 static struct sss{
4 double f;
5 float snd;
6 } sss;
8 #define _offsetof(st,f) ((char *)&((st *) 16)->f - (char *) 16)
10 int main (void) {
11 printf ("+++Struct double-float:\n");
12 printf ("size=%d,align=%d,offset-double=%d,offset-float=%d,\nalign-double=%d,align-float=%d\n",
13 sizeof (sss), __alignof__ (sss),
14 _offsetof (struct sss, f), _offsetof (struct sss, snd),
15 __alignof__ (sss.f), __alignof__ (sss.snd));
16 return 0;