aboutsummaryrefslogtreecommitdiff
path: root/test/integers.tm
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2024-09-15 15:33:47 -0400
committerBruce Hill <bruce@bruce-hill.com>2024-09-15 15:33:47 -0400
commite422079fcced744e3a6247aeb12a09a658989072 (patch)
tree393d5e52ba67dcc822ccfa9a812198edda5e735d /test/integers.tm
parent259c7efcf8c3808d8151d8e15f1167ad2b6f2ca7 (diff)
Add a Byte datatype
Diffstat (limited to 'test/integers.tm')
-rw-r--r--test/integers.tm16
1 files changed, 8 insertions, 8 deletions
diff --git a/test/integers.tm b/test/integers.tm
index e15b9473..363fdfdd 100644
--- a/test/integers.tm
+++ b/test/integers.tm
@@ -11,8 +11,8 @@ func main():
>> 2 * 3 + 4
= 10
- >> 1i8 + 2i16
- = 3_i16
+ >> 1[8] + 2[16]
+ = 3[16]
>> 1 << 10
= 1024
@@ -32,7 +32,7 @@ func main():
>> nums
= "1,2,3,4,5,"
- >> x := 123i64
+ >> x := 123[64]
>> x:format(digits=5)
= "00123"
>> x:hex()
@@ -42,16 +42,16 @@ func main():
>> Int.random(1, 100)
>> Int64.min
- = -9223372036854775808_i64
+ = -9223372036854775808[64]
>> Int64.max
- = 9223372036854775807_i64
+ = 9223372036854775807[64]
- >> 123_i32:hex()
+ >> 123[32]:hex()
= "0x7B"
- >> 123_i16:hex()
+ >> 123[16]:hex()
= "0x7B"
- >> 123_i8:hex()
+ >> 123[8]:hex()
= "0x7B"
>> Int(2.1)