In fact you can use & | ^ on any primitives (I think) and compare their bits.
Yes, I tried this and it works:
But one thing to notice is applying bitwise operator on boolean gives a boolean as output, while doing the same on char and int gives an int back. I guess that proves | is overloaded in java.
[ October 10, 2008: Message edited by: Varun Chopra ]