Add fixed-point types#1560
Merged
Merged
Conversation
|
Member
Author
This was referenced Apr 24, 2026
Merged
BundleMonFiles updated (4)
Unchanged files (143)
Total files change -279B -0.05% Final result: ✅ View report in BundleMon website ➡️ |
Contributor
|
Documentation Preview: https://kit-docs-141tlpauj-anza-tech.vercel.app |
ce87d8d to
f73fabb
Compare
5f84e7a to
17de005
Compare
mcintyre94
approved these changes
Apr 28, 2026
f73fabb to
f35860d
Compare
17de005 to
2ef4868
Compare
2ef4868 to
f04b24e
Compare
ab0548b to
6817c52
Compare
f04b24e to
29d9851
Compare
6817c52 to
e7bf82c
Compare
29d9851 to
aa0861a
Compare
Member
Author
Merge activity
|
This PR is part of the stack implementing the fixed-point number types proposed in #1545. It lands the public type surface that every follow-up PR will build on. Adds the four core types: - `Signedness` — `'signed' | 'unsigned'`. - `RoundingMode` — `'floor' | 'ceil' | 'trunc' | 'round' | 'strict'`. The `'round'` mode breaks ties away from zero (e.g. `0.5 → 1`, `-0.5 → -1`, `-1.5 → -2`), which is symmetric around zero and differs from `Math.round`. The `'strict'` mode rejects inputs that would require rounding and throws instead. - `BinaryFixedPoint<TSignedness, TTotalBits, TFractionalBits>` — a fixed-point value whose scale is a power of 2. - `DecimalFixedPoint<TSignedness, TTotalBits, TDecimals>` — a fixed-point value whose scale is a power of 10.
aa0861a to
b015176
Compare
Contributor
|
🔎💬 Inkeep AI search and chat service is syncing content for source 'Solana Kit Docs' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

This PR is part of the stack implementing the fixed-point number types proposed in #1545. It lands the public type surface that every follow-up PR will build on.
Adds the four core types:
Signedness—'signed' | 'unsigned'.RoundingMode—'floor' | 'ceil' | 'trunc' | 'round' | 'strict'. The'round'mode breaks ties away from zero (e.g.0.5 → 1,-0.5 → -1,-1.5 → -2), which is symmetric around zero and differs fromMath.round. The'strict'mode rejects inputs that would require rounding and throws instead.BinaryFixedPoint<TSignedness, TTotalBits, TFractionalBits>— a fixed-point value whose scale is a power of 2.DecimalFixedPoint<TSignedness, TTotalBits, TDecimals>— a fixed-point value whose scale is a power of 10.