@@ -3483,7 +3483,14 @@ decode0 table byte =
3483 let !t = table `unsafePeekElemOff` fromIntegral byte
3483 let !t = table `unsafePeekElemOff` fromIntegral byte
3484 !codep' = (0xff `shiftR` (fromIntegral t)) .&. fromIntegral byte
3484 !codep' = (0xff `shiftR` (fromIntegral t)) .&. fromIntegral byte
3485 !state' = table `unsafePeekElemOff` (256 + fromIntegral t)
3485 !state' = table `unsafePeekElemOff` (256 + fromIntegral t)
3486+ in assert ((byte > 0x7f || error showByte)
3487+ && (state' /= 0 || error (showByte ++ showState state')))
3486− in (Tuple' state' codep')
3488+ (Tuple' state' codep')
3492+ showByte = "decode0: Invalid byte: " ++ show byte
3493+ showState st = " state: " ++ show st ++ " table: " ++ show table
3488-- When the state is not 0
3495-- When the state is not 0
3489{-# INLINE decode1 #-}
3496{-# INLINE decode1 #-}