Hacker News new | past | comments | ask | show | jobs | submit login

So `unsigned flag:1`?



After you set all the pragmas or attributes to not add any additional padding/alignment, and that you really, really mean it. Maybe add a few static asserts so you know at compile time if you got the size right.

These are not standard, so you need some preprocessor magic to choose the right thing. And so on...


I just use 'bool flag:1' in C.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: