At 7:57 AM +0100 2/17/00, Aaron Ardiri wrote:
>  a shift right ">>" works the way you intend if the number is
>  unsigned.. however, if you have a negative number, the shifting
>  works slightly different.
>
>  -32 >> 1 should give you -16 right? and what does this tell
>  you just by looking at it? *the* SIGN bit is maintained, and
>  hence the MSB is not removed :>

I don't think you can rely on the behavior of >> on signed integers in C.

Danny

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palm.com/devzone/mailinglists.html

Reply via email to