Re: byte data type



Roedy Green wrote:
> Java went with the signed tradition even though nowadays 99% of the
> time you want unsigned. Perhaps sun hardware is signed byte only.

I suspect most of the time it makes absolutely no difference whether it
is signed or unsigned. For the main operations on bytes (the bitwise
ones) signedness makes no difference except for right shift (but that's
why there's >> and >>>).

Just curious. What other operations are you doing on bytes where the
signedness matters? I would consider printing out bytes in decimal
or doing division on them to be uncommon, but maybe I am wrong.

.