1  struct foo
       2  {
       3    unsigned half:16;
       4    unsigned long whole:32 __attribute__ ((packed));
       5  };
       6  
       7  f (struct foo *q)
       8  {
       9    if (q->half != 0x1234)
      10      abort ();
      11    if (q->whole != 0x56789abcL)
      12      abort ();
      13  }
      14  
      15  main ()
      16  {
      17    struct foo bar;
      18  
      19    bar.half = 0x1234;
      20    bar.whole = 0x56789abcL;
      21    f (&bar);
      22    exit (0);
      23  }