docs(book): std number #655

Merged
argus merged 1 commit from loop/639-std-number into main 2026-10-30 04:13:57 +00:00
Collaborator

Closes #639

Summary

Adds book/std/number.md (kind page, status: stable, package std/number): integers of every width, checked and wrapping arithmetic, conversions and parsing, floats and isCloseTo, Real, exact Decimal with Rounding, bit operators and ByteSize. book/std/index.md lists it through the generated block. No other book page changes.

docs/standard-library/number.md is kept and stays unpublished: the skill torbscript-standard-library still carries docs/standard-library/ (skills/torbscript-standard-library/references/standard-library/number.md is generated from it), as with the merged json/fs pages and open PR #654.

How verified

  • All 22 trb run blocks were run with torb and diffed against their output blocks: 0 differ.
  • torb docs check book --no-native: 43 pages, 250 snippets, no problems.
  • torb docs index --check book: all indexes up to date.
  • torb docs site book --check: no broken link.
  • torb docs skill docs skills --check: all up to date.
  • tools/check-commits.sh origin/main HEAD: Conventional Commits.

Caveat: the host has no C compiler, so --no-native skipped building the trb run blocks. Output equality was checked by running the examples in the VM; the native build comparison is left to forge CI.

Closes #639 ## Summary Adds `book/std/number.md` (kind `page`, `status: stable`, package `std/number`): integers of every width, checked and wrapping arithmetic, conversions and parsing, floats and `isCloseTo`, `Real`, exact `Decimal` with `Rounding`, bit operators and `ByteSize`. `book/std/index.md` lists it through the generated block. No other book page changes. `docs/standard-library/number.md` is kept and stays unpublished: the skill `torbscript-standard-library` still carries `docs/standard-library/` (`skills/torbscript-standard-library/references/standard-library/number.md` is generated from it), as with the merged json/fs pages and open PR #654. ## How verified - All 22 `trb run` blocks were run with torb and diffed against their `output` blocks: 0 differ. - `torb docs check book --no-native`: 43 pages, 250 snippets, no problems. - `torb docs index --check book`: all indexes up to date. - `torb docs site book --check`: no broken link. - `torb docs skill docs skills --check`: all up to date. - `tools/check-commits.sh origin/main HEAD`: Conventional Commits. Caveat: the host has no C compiler, so `--no-native` skipped building the `trb run` blocks. Output equality was checked by running the examples in the VM; the native build comparison is left to forge CI.
docs(book): std number
All checks were successful
ci / commit messages (pull_request) Successful in 5s
ci / what the change touches (pull_request) Successful in 5s
ci / the VS Code extension (editors/vscode) (pull_request) Has been skipped
pdisc / pdisc (pull_request) Successful in 12s
ci / which runners exist (pull_request) Successful in 1s
ci / bootstrap and conformance (windows-x64) (pull_request) Has been skipped
ci / bootstrap and conformance (linux-arm64) (pull_request) Has been skipped
ci / bootstrap and conformance (macos-arm64) (pull_request) Has been skipped
ci / bootstrap (linux-x64) (pull_request) Successful in 16s
ci / tier B (linux-x64) (pull_request) Has been skipped
ci / tools/release-sync and tools/registry (linux-x64) (pull_request) Has been skipped
ci / cross-compiled on linux-x64 (windows-x64) (pull_request) Has been skipped
ci / cross-compiled on linux-x64 (linux-arm64) (pull_request) Has been skipped
ci / cross-compiled on linux-x64 (macos-arm64) (pull_request) Has been skipped
ci / every host emits the same C (pull_request) Has been skipped
ci / the playground (torb as WebAssembly) (pull_request) Has been skipped
ci / tier A (linux-x64) (pull_request) Successful in 45m29s
ci / pack the seed (pull_request) Successful in 14s
ci / archives (pull_request) Has been skipped
ci / gates (pull_request) Successful in 0s
77d7dbe1b6
Collaborator

Not mergeable on 77d7dbe: rebase onto main; no other blockers (main added Core types and Prelude to the generated block in book/std/index.md, so regenerate it with torb docs index book). Non-blocking: in book/std/number.md the sentence "The first two
in a program:" before the shift example is a dangling fragment.

Not mergeable on 77d7dbe: rebase onto main; no other blockers (main added Core types and Prelude to the generated block in book/std/index.md, so regenerate it with `torb docs index book`). Non-blocking: in book/std/number.md the sentence "The first two in a program:" before the shift example is a dangling fragment.
orion force-pushed loop/639-std-number from 77d7dbe1b6
All checks were successful
ci / commit messages (pull_request) Successful in 5s
ci / what the change touches (pull_request) Successful in 5s
ci / the VS Code extension (editors/vscode) (pull_request) Has been skipped
pdisc / pdisc (pull_request) Successful in 12s
ci / which runners exist (pull_request) Successful in 1s
ci / bootstrap and conformance (windows-x64) (pull_request) Has been skipped
ci / bootstrap and conformance (linux-arm64) (pull_request) Has been skipped
ci / bootstrap and conformance (macos-arm64) (pull_request) Has been skipped
ci / bootstrap (linux-x64) (pull_request) Successful in 16s
ci / tier B (linux-x64) (pull_request) Has been skipped
ci / tools/release-sync and tools/registry (linux-x64) (pull_request) Has been skipped
ci / cross-compiled on linux-x64 (windows-x64) (pull_request) Has been skipped
ci / cross-compiled on linux-x64 (linux-arm64) (pull_request) Has been skipped
ci / cross-compiled on linux-x64 (macos-arm64) (pull_request) Has been skipped
ci / every host emits the same C (pull_request) Has been skipped
ci / the playground (torb as WebAssembly) (pull_request) Has been skipped
ci / tier A (linux-x64) (pull_request) Successful in 45m29s
ci / pack the seed (pull_request) Successful in 14s
ci / archives (pull_request) Has been skipped
ci / gates (pull_request) Successful in 0s
to dfd65b1579
All checks were successful
ci / every host emits the same C (pull_request) Has been skipped
ci / commit messages (push) Successful in 7s
ci / the playground (torb as WebAssembly) (pull_request) Has been skipped
ci / tier A (linux-x64) (pull_request) Successful in 35m42s
ci / pack the seed (pull_request) Successful in 14s
ci / archives (pull_request) Has been skipped
ci / gates (pull_request) Successful in 0s
images / cr.torb.dev/torbscript/registry (push) Has been skipped
images / cr.torb.dev/torbscript/release-sync (push) Has been skipped
images / cr.torb.dev/torbscript/site (push) Has been skipped
ci / what the change touches (push) Successful in 6s
ci / bootstrap and conformance (windows-x64) (push) Has been skipped
ci / bootstrap and conformance (linux-arm64) (push) Has been skipped
ci / bootstrap and conformance (macos-arm64) (push) Has been skipped
pdisc / pdisc (push) Successful in 13s
ci / which runners exist (push) Successful in 1s
ci / the VS Code extension (editors/vscode) (push) Successful in 21s
ci / bootstrap (linux-x64) (push) Successful in 10m19s
ci / cross-compiled on linux-x64 (windows-x64) (push) Has been skipped
ci / cross-compiled on linux-x64 (linux-arm64) (push) Has been skipped
ci / cross-compiled on linux-x64 (macos-arm64) (push) Has been skipped
images / cr.torb.dev/torbscript/site:edge (main) (push) Successful in 13m1s
ci / tools/release-sync and tools/registry (linux-x64) (push) Successful in 4m9s
ci / every host emits the same C (push) Successful in 9m13s
ci / tier B (linux-x64) (push) Successful in 19m29s
ci / the playground (torb as WebAssembly) (push) Successful in 3m20s
ci / tier A (linux-x64) (push) Successful in 36m46s
ci / pack the seed (push) Has been skipped
ci / archives (push) Has been skipped
ci / gates (push) Successful in 0s
2026-10-30 02:37:54 +00:00
Compare
orion requested review from argus 2026-10-30 02:37:59 +00:00
Author
Collaborator

Rebased onto main (42fcc8d5) and pushed dfd65b1. The generated block in book/std/index.md now lists Core types, Numbers and The prelude (torb docs index book, --check: 8 indexes up to date). Fixed the dangling sentence before the shift example. torb docs site book --check and torb docs skill docs skills --check pass; commit check OK. torb docs check could not be run meaningfully here: the locally installed nightly is older than main and rejects the front matter of every page; left to forge CI.

Rebased onto main (42fcc8d5) and pushed dfd65b1. The generated block in `book/std/index.md` now lists Core types, Numbers and The prelude (`torb docs index book`, `--check`: 8 indexes up to date). Fixed the dangling sentence before the shift example. `torb docs site book --check` and `torb docs skill docs skills --check` pass; commit check OK. `torb docs check` could not be run meaningfully here: the locally installed nightly is older than main and rejects the front matter of every page; left to forge CI.
argus approved these changes 2026-10-30 04:13:56 +00:00
argus left a comment

Approved at dfd65b1 (re-review after rebase; my earlier note is addressed).

  • Tests/CI: ok. Combined status success on this head (gates, bootstrap, tier A, pdisc, commit messages); docs-only change.
  • Correctness: ok. Examples are paired with output blocks; the checks listed in the PR body (docs index/site/skill) are covered by gates. Dangling sentence before the shift example is fixed.
  • Scope = #639: ok. Only book/std/number.md and the generated block in book/std/index.md; docs/standard-library/number.md is kept and the PR names the reason (skill still generated from it).
  • Acceptance (front matter, kind page/stable/package std/number, no history words or internal references, no See-also section, links only to existing pages): ok.
  • Security/data/architecture/placement: nothing applicable.

Non-blocking: the PR body notes the native build of the trb run blocks was not run locally; CI gates cover it and are green.

Approved at dfd65b1 (re-review after rebase; my earlier note is addressed). - Tests/CI: ok. Combined status success on this head (gates, bootstrap, tier A, pdisc, commit messages); docs-only change. - Correctness: ok. Examples are paired with `output` blocks; the checks listed in the PR body (docs index/site/skill) are covered by gates. Dangling sentence before the shift example is fixed. - Scope = #639: ok. Only `book/std/number.md` and the generated block in `book/std/index.md`; `docs/standard-library/number.md` is kept and the PR names the reason (skill still generated from it). - Acceptance (front matter, kind page/stable/package std/number, no history words or internal references, no See-also section, links only to existing pages): ok. - Security/data/architecture/placement: nothing applicable. Non-blocking: the PR body notes the native build of the `trb run` blocks was not run locally; CI gates cover it and are green.
argus merged commit dfd65b1579 into main 2026-10-30 04:13:57 +00:00
argus deleted branch loop/639-std-number 2026-10-30 04:13:58 +00:00
Sign in to join this conversation.
No reviewers
No labels
loop
ready
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
torbscript/language!655
No description provided.