diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2024-11-03 15:48:13 -0500 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2024-11-03 15:48:13 -0500 |
| commit | 3743913ce2c5bc37f899d437c09b60cbb3bc6dea (patch) | |
| tree | cbbe7fe8debc7651c915b727f608bf2bcfa151ea /test | |
| parent | 792743dff3b4af6df030a53e447b28a8a3e8b072 (diff) | |
Add unsigned integer shifts
Diffstat (limited to 'test')
| -rw-r--r-- | test/integers.tm | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/integers.tm b/test/integers.tm index 8d34dfc0..225baab5 100644 --- a/test/integers.tm +++ b/test/integers.tm @@ -17,6 +17,16 @@ func main(): >> 1 << 10 = 1024 + !! Signed and unsigned bit shifting: + >> -2[64] << 1 + = -4[64] + >> -2[64] <<[u] 1 + = -4[64] + >> -2[64] >> 1 + = -1[64] + >> -2[64] >>[u] 1 + = 9223372036854775807[64] + >> 3 and 2 = 2 |
