You're replying to a comment by Ben.

Ben Permalink
January 14, 2010, 10:36

your B_SET macros has a LP-64 portability problem.

unsigned long_t x = 0;B_SET(x, 31);assert(x == (1ULThe assertion will fail because with ((x) |= (1#define BIT_MASK(x,n) ( ((__typeof((x)))1)I think, 1LL should also work on most platforms.Btw: Any naming suggestions for macros that do not modifytheir first argument but simply create a new value?Basically, |= vs. |

Reply To This Comment

(why do I need your e-mail?)

(Your twitter name, if you have one. (I'm @pkrumins, btw.))

Type the first letter of your name: (just to make sure you're a human)

Please preview the comment before submitting to make sure it's OK.