Fix topBit always returning False

This commit is contained in:
Joscha 2019-11-08 18:45:47 +00:00
parent 112a49a7b7
commit 4f5817c032

View file

@ -31,7 +31,7 @@ type SmallValue = Word16
type Opcode = Word4
topBit :: (FiniteBits b) => b -> Bool
topBit b = testBit b $ finiteBitSize b
topBit b = testBit b $ finiteBitSize b - 1
bytesToWord :: (Word8, Word8, Word8) -> MimaWord
bytesToWord (w1, w2, w3) =