aboutsummaryrefslogtreecommitdiff
path: root/man
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2026-01-19 20:51:26 -0500
committerBruce Hill <bruce@bruce-hill.com>2026-01-19 20:52:23 -0500
commitf905f1e4d1c77410931dc5ebfd8bcf466864a3e2 (patch)
tree32d52ad87f303237e451c90c1a33b12217a1c6e5 /man
parenta36f149d0837f4424aeda1a1853f08c27aeafa44 (diff)
Allow parsing `123.foo()` as `(123).foo()`
Diffstat (limited to 'man')
-rw-r--r--man/man3/tomo-Int.choose.36
-rw-r--r--man/man3/tomo-Int.clamped.36
-rw-r--r--man/man3/tomo-Int.factorial.36
-rw-r--r--man/man3/tomo-Int.get_bit.312
-rw-r--r--man/man3/tomo-Int.hex.36
-rw-r--r--man/man3/tomo-Int.is_between.312
-rw-r--r--man/man3/tomo-Int.is_prime.38
-rw-r--r--man/man3/tomo-Int.next_prime.36
-rw-r--r--man/man3/tomo-Int.octal.36
-rw-r--r--man/man3/tomo-Int.onward.36
-rw-r--r--man/man3/tomo-Int.prev_prime.36
-rw-r--r--man/man3/tomo-Int.sqrt.38
-rw-r--r--man/man3/tomo-Int.to.312
13 files changed, 50 insertions, 50 deletions
diff --git a/man/man3/tomo-Int.choose.3 b/man/man3/tomo-Int.choose.3
index 1e5c705b..f8b310e1 100644
--- a/man/man3/tomo-Int.choose.3
+++ b/man/man3/tomo-Int.choose.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.choose 3 2025-11-29 "Tomo man-pages"
+.TH Int.choose 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.choose \- binomial coefficient
.SH LIBRARY
@@ -30,7 +30,7 @@ The binomial coefficient, equivalent to the number of ways to uniquely choose `k
.SH EXAMPLES
.EX
-assert (4).choose(2) == 6
+assert 4.choose(2) == 6
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.clamped.3 b/man/man3/tomo-Int.clamped.3
index 5d846a21..5fee2f79 100644
--- a/man/man3/tomo-Int.clamped.3
+++ b/man/man3/tomo-Int.clamped.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.clamped 3 2025-11-29 "Tomo man-pages"
+.TH Int.clamped 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.clamped \- clamp an integer
.SH LIBRARY
@@ -31,7 +31,7 @@ The first argument clamped between the other two arguments.
.SH EXAMPLES
.EX
-assert (2).clamped(5, 10) == 5
+assert 2.clamped(5, 10) == 5
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.factorial.3 b/man/man3/tomo-Int.factorial.3
index e7105287..f4f0572b 100644
--- a/man/man3/tomo-Int.factorial.3
+++ b/man/man3/tomo-Int.factorial.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.factorial 3 2025-11-29 "Tomo man-pages"
+.TH Int.factorial 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.factorial \- factorial
.SH LIBRARY
@@ -29,7 +29,7 @@ The factorial of the given integer.
.SH EXAMPLES
.EX
-assert (10).factorial() == 3628800
+assert 10.factorial() == 3628800
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.get_bit.3 b/man/man3/tomo-Int.get_bit.3
index bf9f11b2..de53c38d 100644
--- a/man/man3/tomo-Int.get_bit.3
+++ b/man/man3/tomo-Int.get_bit.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.get_bit 3 2025-11-29 "Tomo man-pages"
+.TH Int.get_bit 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.get_bit \- check whether a bit is set
.SH LIBRARY
@@ -33,10 +33,10 @@ For fixed-size integers, the bit index must be between 1 and the number of bits
.SH EXAMPLES
.EX
-assert (6).get_bit(1) == no
-assert (6).get_bit(2) == yes
-assert (6).get_bit(3) == yes
-assert (6).get_bit(4) == no
+assert 6.get_bit(1) == no
+assert 6.get_bit(2) == yes
+assert 6.get_bit(3) == yes
+assert 6.get_bit(4) == no
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.hex.3 b/man/man3/tomo-Int.hex.3
index 37fe45e4..d61e363a 100644
--- a/man/man3/tomo-Int.hex.3
+++ b/man/man3/tomo-Int.hex.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.hex 3 2025-11-29 "Tomo man-pages"
+.TH Int.hex 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.hex \- convert to hexidecimal
.SH LIBRARY
@@ -32,7 +32,7 @@ The hexadecimal string representation of the integer.
.SH EXAMPLES
.EX
-assert (255).hex(digits=4, uppercase=yes, prefix=yes) == "0x00FF"
+assert 255.hex(digits=4, uppercase=yes, prefix=yes) == "0x00FF"
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.is_between.3 b/man/man3/tomo-Int.is_between.3
index fd54eb41..d902f9a6 100644
--- a/man/man3/tomo-Int.is_between.3
+++ b/man/man3/tomo-Int.is_between.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.is_between 3 2025-12-31 "Tomo man-pages"
+.TH Int.is_between 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.is_between \- test if an int is in a range
.SH LIBRARY
@@ -31,10 +31,10 @@ b Int The other end of the range to check (inclusive).
.SH EXAMPLES
.EX
-assert (7).is_between(1, 10) == yes
-assert (7).is_between(10, 1) == yes
-assert (7).is_between(100, 200) == no
-assert (7).is_between(1, 7) == yes
+assert 7.is_between(1, 10) == yes
+assert 7.is_between(10, 1) == yes
+assert 7.is_between(100, 200) == no
+assert 7.is_between(1, 7) == yes
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.is_prime.3 b/man/man3/tomo-Int.is_prime.3
index 5dc2c826..1d3d44a7 100644
--- a/man/man3/tomo-Int.is_prime.3
+++ b/man/man3/tomo-Int.is_prime.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.is_prime 3 2025-11-29 "Tomo man-pages"
+.TH Int.is_prime 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.is_prime \- check if an integer is prime
.SH LIBRARY
@@ -33,8 +33,8 @@ This function is _probabilistic_. With the default arguments, the chances of get
.SH EXAMPLES
.EX
-assert (7).is_prime() == yes
-assert (6).is_prime() == no
+assert 7.is_prime() == yes
+assert 6.is_prime() == no
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.next_prime.3 b/man/man3/tomo-Int.next_prime.3
index ab2c4307..cc577d0f 100644
--- a/man/man3/tomo-Int.next_prime.3
+++ b/man/man3/tomo-Int.next_prime.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.next_prime 3 2025-11-29 "Tomo man-pages"
+.TH Int.next_prime 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.next_prime \- get the next prime
.SH LIBRARY
@@ -32,7 +32,7 @@ This function is _probabilistic_, but the chances of getting an incorrect answer
.SH EXAMPLES
.EX
-assert (11).next_prime() == 13
+assert 11.next_prime() == 13
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.octal.3 b/man/man3/tomo-Int.octal.3
index 627a2e9f..dc8ddf92 100644
--- a/man/man3/tomo-Int.octal.3
+++ b/man/man3/tomo-Int.octal.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.octal 3 2025-11-29 "Tomo man-pages"
+.TH Int.octal 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.octal \- convert to octal
.SH LIBRARY
@@ -31,7 +31,7 @@ The octal string representation of the integer.
.SH EXAMPLES
.EX
-assert (64).octal(digits=4, prefix=yes) == "0o0100"
+assert 64.octal(digits=4, prefix=yes) == "0o0100"
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.onward.3 b/man/man3/tomo-Int.onward.3
index 596cf842..6cf9ffc8 100644
--- a/man/man3/tomo-Int.onward.3
+++ b/man/man3/tomo-Int.onward.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.onward 3 2025-11-29 "Tomo man-pages"
+.TH Int.onward 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.onward \- iterate from a number onward
.SH LIBRARY
@@ -31,7 +31,7 @@ An iterator function that counts onward from the starting integer.
.SH EXAMPLES
.EX
nums : &[Int] = &[]
-for i in (5).onward()
+for i in 5.onward()
nums.insert(i)
stop if i == 10
assert nums[] == [5, 6, 7, 8, 9, 10]
diff --git a/man/man3/tomo-Int.prev_prime.3 b/man/man3/tomo-Int.prev_prime.3
index 87f7be36..6b4564df 100644
--- a/man/man3/tomo-Int.prev_prime.3
+++ b/man/man3/tomo-Int.prev_prime.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.prev_prime 3 2025-11-29 "Tomo man-pages"
+.TH Int.prev_prime 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.prev_prime \- get the previous prime
.SH LIBRARY
@@ -32,7 +32,7 @@ This function is _probabilistic_, but the chances of getting an incorrect answer
.SH EXAMPLES
.EX
-assert (11).prev_prime() == 7
+assert 11.prev_prime() == 7
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.sqrt.3 b/man/man3/tomo-Int.sqrt.3
index 6a3e7eaf..fa7013a5 100644
--- a/man/man3/tomo-Int.sqrt.3
+++ b/man/man3/tomo-Int.sqrt.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.sqrt 3 2025-11-29 "Tomo man-pages"
+.TH Int.sqrt 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.sqrt \- square root
.SH LIBRARY
@@ -29,8 +29,8 @@ The integer part of the square root of `x`.
.SH EXAMPLES
.EX
-assert (16).sqrt() == 4
-assert (17).sqrt() == 4
+assert 16.sqrt() == 4
+assert 17.sqrt() == 4
.EE
.SH SEE ALSO
.BR Tomo-Int (3)
diff --git a/man/man3/tomo-Int.to.3 b/man/man3/tomo-Int.to.3
index 9c0fe4dc..e5ba9158 100644
--- a/man/man3/tomo-Int.to.3
+++ b/man/man3/tomo-Int.to.3
@@ -1,8 +1,8 @@
'\" t
-.\" Copyright (c) 2025 Bruce Hill
+.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
-.TH Int.to 3 2025-11-29 "Tomo man-pages"
+.TH Int.to 3 2026-01-19 "Tomo man-pages"
.SH NAME
Int.to \- iterate a range of integers
.SH LIBRARY
@@ -31,16 +31,16 @@ An iterator function that returns each integer in the given range (inclusive).
.SH EXAMPLES
.EX
-iter := (2).to(5)
+iter := 2.to(5)
assert iter() == 2
assert iter() == 3
assert iter() == 4
assert iter() == 5
assert iter() == none
-assert [x for x in (2).to(5)] == [2, 3, 4, 5]
-assert [x for x in (5).to(2)] == [5, 4, 3, 2]
-assert [x for x in (2).to(5, step=2)] == [2, 4]
+assert [x for x in 2.to(5)] == [2, 3, 4, 5]
+assert [x for x in 5.to(2)] == [5, 4, 3, 2]
+assert [x for x in 2.to(5, step=2)] == [2, 4]
.EE
.SH SEE ALSO
.BR Tomo-Int (3)