Added some out of place bitwise operations