Dr. Dobbs Dev. Update 1/5 July 94 & Schneier

Alan Barrett barrett at daisy.ee.und.ac.za
Sun Jul 3 08:26:56 PDT 1994


> >In C, {int j... if(j & (j-1)) not_exactly_one_bit; ...}

C code that does bit twiddling should almost always use unsigned
rather than signed integers, or you may get some nasty surprises on C
implementations that do not use two's complement representation for
signed integers.

--apb (Alan Barrett)






More information about the cypherpunks-legacy mailing list