Implement std/math.wrapping_* as NCA-backed modulo arithmetic primitives #9

Open
opened 2026-05-04 11:48:49 -04:00 by insidiousfiddler · 0 comments
insidiousfiddler commented 2026-05-04 11:48:49 -04:00 (Migrated from codefloe.com)

std/math.wrapping_* should be implemented as ordinary stdlib functions backed by paired .nca implementations.

These functions are needed for algorithms that intentionally require modulo arithmetic, such as PCG, hash functions, checksums, cryptographic bit-mixing, and other low-level numeric routines.

This should be separate from the compiler fix for normal NC arithmetic overflow.

`std/math.wrapping_*` should be implemented as ordinary stdlib functions backed by paired `.nca` implementations. These functions are needed for algorithms that intentionally require modulo arithmetic, such as PCG, hash functions, checksums, cryptographic bit-mixing, and other low-level numeric routines. This should be separate from the compiler fix for normal NC arithmetic overflow.
Sign in to join this conversation.
No project
No assignees
1 participant
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
nclang/ncc#9
No description provided.