haskell/c2hs — pull request #61 by facundominguez (2013-11-30 18:10:40+00:00)
Title: Fixes size and alignment computation of bitfields.

Tested on windows i386 with haskell-platform 2013.2.0.0 and linux x86_64.

Without this fix, the following struct would show different
sizes with c2hs {#sizeof bitfields #} and gcc sizeof(bitfields).

typedef struct {
unsigned int b0 : 31;
unsigned int b30 : 1;
} bitfields;

May affect the issues reported in:
https://github.com/haskell/c2hs/search?q=bitfields&ref=cmdform&type=Issues

This patch is based on 0.16.5 rather than HEAD to avoid a supposed regression reported in:
https://github.com/haskell/c2hs/issues/60
Would merge well with current master though.