]>
Commit | Line | Data |
---|---|---|
1 | signature SUQ = | |
2 | sig | |
3 | val Word32_lsh : Word32.word * Word32.word -> Word32.word | |
4 | val Word32_rsh : Word32.word * Word32.word -> Word32.word | |
5 | end | |
6 | ||
7 | structure Suq :> SUQ = | |
8 | struct | |
9 | fun loseBit (x: Word32.word) : word = Word31.fromInt (Word32.toInt x) | |
10 | fun Word32_lsh (a, b) = Word32.<< (a, loseBit b) | |
11 | fun Word32_rsh (a, b) = Word32.~>> (a, loseBit b) | |
12 | end |