I was surprised today to find that C and Haskell differ on the precedence of addition and bit-wise and.

In Haskell, bit-wise-and (.&.) binds tighter. In C, it's the other way around.

While I like Haskell's precedence better, this was a gotcha; and I wondered if this behavior is documented somewhere. I looked through the Haskell wiki, but couldn't find anything pertinent.

Discrepancies are always problematic. Without bike-shedding a lot, does anyone know if this was a conscious decision or merely a more natural one to take?

Cheers,

-Levent.