module Data.Bits

Malcolm Wallace Malcolm.Wallace at cs.york.ac.uk
Fri Sep 6 13:25:56 EDT 2002


I have just been implementing the library module `Data.Bits' for nhc98,
as part of an effort to bring that compiler up-to-date with the latest FFI
spec.

The FFI spec says that the operations called 'shift' and 'rotate',
shift and rotate their argument to the right.  However, the GHC
implementation in CVS shifts and rotates to the left, and is documented
to do so.

Who is right?  FWIW, before I read any documentation I expected the
undecorated forms to be rightward.

Regards,
    Malcolm



More information about the FFI mailing list