Simon Josefsson <[EMAIL PROTECTED]> writes:

> +#define rotl32(x,n) \
> +  ((((x) << ((uint16_t)(n))) | ((x) >> (32 - (uint16_t)(n)))) & 0xFFFFFFFF)

I suggest using inline functions rather than macros, to avoid hassles
with double-evaluating arguments.  That way, you won't need any casts.
The casts in this code are not right, anyway; in C, the shift count N
is supposed to be of type int, regardless of the type of the value X
being shifted.


Reply via email to