Better support for conversions between number types.

This commit is contained in:
2020-01-10 09:04:47 -10:00
parent 8c5f18cb7c
commit 4b8d0b3f09
14 changed files with 96 additions and 35 deletions

View File

@@ -26,8 +26,8 @@ shiftOps = File {
testCase = Just generateTests
}
declareShiftOperators :: Word -> SourceFile Span
declareShiftOperators bitsize =
declareShiftOperators :: Word -> [Word] -> SourceFile Span
declareShiftOperators bitsize _ =
let struct_name = mkIdent ("U" ++ show bitsize)
entries = bitsize `div` 64
unsignedShifts = generateUnsigneds struct_name