aboutsummaryrefslogtreecommitdiff
path: root/test/tables.tm
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2025-04-06 14:20:18 -0400
committerBruce Hill <bruce@bruce-hill.com>2025-04-06 14:20:18 -0400
commit2bb2ff871fa1761478442bec5f6a32c9428360a1 (patch)
tree9b73df7a0c50c02353ae7bca7c2cd54788ef0077 /test/tables.tm
parent59845e610f2c90474f34079d27b5f1e07071ded4 (diff)
Change method calls to use `foo.baz()` instead of `foo:baz()`
Diffstat (limited to 'test/tables.tm')
-rw-r--r--test/tables.tm16
1 files changed, 8 insertions, 8 deletions
diff --git a/test/tables.tm b/test/tables.tm
index 20d76269..a5f51520 100644
--- a/test/tables.tm
+++ b/test/tables.tm
@@ -58,7 +58,7 @@ func main():
= {2=20, 3=30, 4=40}
>> t3 := @{1=10, 2=20, 3=30}
- >> t3:remove(3)
+ >> t3.remove(3)
>> t3
= @{1=10, 2=20}
@@ -70,13 +70,13 @@ func main():
= 20
>> plain[456] or -999
= -999
- >> plain:has(2)
+ >> plain.has(2)
= yes
- >> plain:has(456)
+ >> plain.has(456)
= no
>> fallback := {4=40; fallback=plain}
- >> fallback:has(1)
+ >> fallback.has(1)
= yes
>> fallback[1] or -999
= 10
@@ -96,10 +96,10 @@ func main():
>> {1=1, 2=2} <> {2=2, 1=1}
= Int32(0)
- >> ints : [{Int=Int}] = [{}, {0=0}, {99=99}, {1=1, 2=2, 3=3}, {1=1, 99=99, 3=3}, {1=1, 2=-99, 3=3}, {1=1, 99=-99, 3=4}]:sorted()
+ >> ints : [{Int=Int}] = [{}, {0=0}, {99=99}, {1=1, 2=2, 3=3}, {1=1, 99=99, 3=3}, {1=1, 2=-99, 3=3}, {1=1, 99=-99, 3=4}].sorted()
= [{}, {0=0}, {1=1, 2=-99, 3=3}, {1=1, 2=2, 3=3}, {1=1, 99=99, 3=3}, {1=1, 99=-99, 3=4}, {99=99}]
- >> other_ints : [{Int}] = [{/}, {1}, {2}, {99}, {0, 3}, {1, 2}, {99}]:sorted()
+ >> other_ints : [{Int}] = [{/}, {1}, {2}, {99}, {0, 3}, {1, 2}, {99}].sorted()
= [{/}, {0, 3}, {1}, {1, 2}, {2}, {99}, {99}]
do:
@@ -109,9 +109,9 @@ func main():
= 10
>> counter["y"]
= 0
- >> counter:has("x")
+ >> counter.has("x")
= yes
- >> counter:has("y")
+ >> counter.has("y")
= no
>> counter["y"] += 1