Skip to content

Conversation

@novusnota
Copy link
Collaborator

@novusnota novusnota commented Dec 22, 2025

Closes #1594. Also, somewhat enhanced and rearranged the page. Other tasks & pages were not done the same way and were styleguide-following improvements.

@novusnota
Copy link
Collaborator Author

/review

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No documentation issues detected.

@novusnota novusnota marked this pull request as ready for review December 22, 2025 05:01
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No documentation issues detected.

@novusnota novusnota changed the title feat(tolk): align numbers page with the styleguide feat(tolk): align numbers page with the styleguide and enhance it further Dec 22, 2025
Comment on lines +20 to +26
| Name | Inclusive range | Space taken | Notes |
| -------------------- | ----------------------- | ---------------------- | --------------------------------------------------------------------- |
| Unsigned `coins` | $0 to 2^{120}-1$ | Between 4 and 124 bits | They represent nanoToncoin, where $10^9$ nanoToncoin equals 1 Toncoin |
| Unsigned `varuint16` | Same as `coins` | Same as `coins` | Rarely used |
| Unsigned `varuint32` | $0 to 2^{248}-1$ | Between 5 and 253 bits | Rarely used |
| Signed `varint16` | $-2^{119} to 2^{119}-1$ | Same as `coins` | Rarely used |
| Signed `varint32` | $-2^{247} to 2^{247}-1$ | Between 5 and 253 bits | Rarely used |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

| Name                 | Inclusive range                       | Space taken            | Notes                                                                         |
|----------------------|---------------------------------------|------------------------|-------------------------------------------------------------------------------|
| Unsigned `coins`     | 0 to 2<sup>120</sup>-1                | Between 4 and 124 bits | They represent nanoToncoin, where 10<sup>9</sup> nanoToncoin equals 1 Toncoin |
| Unsigned `varuint16` | Same as `coins`                       | Same as `coins`        | Rarely used                                                                   |
| Unsigned `varuint32` | 0 to 2<sup>248</sup>-1                | Between 5 and 253 bits | Rarely used                                                                   |
| Signed `varint16`    | -2<sup>119</sup> to 2<sup>119</sup>-1 | Same as `coins`        | Rarely used                                                                   |
| Signed `varint32`    | -2<sup>247</sup> to 2<sup>247</sup>-1 | Between 5 and 253 bits | Rarely used                                                                   |

Comment on lines +13 to +16
| Name | Inclusive range | Space taken | Examples |
| ---------------- | ----------------------- | ---------------------------------------- | ------------------------------ |
| Signed `intN` | $-2^{N-1} to 2^{N-1}-1$ | `N` bits, where `N` is between 1 and 257 | `int32`, `int257`, `int7` |
| Unsigned `uintN` | $0 to 2^{N}-1$ | `N` bits, where `N` is between 1 and 256 | `uint16`, `uint256`, `uint119` |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

| Name             | Inclusive range                       | Space taken                              | Examples                       |
|------------------|---------------------------------------|------------------------------------------|--------------------------------|
| Signed `intN`    | -2<sup>N-1</sup> to 2<sup>N-1</sup>-1 | `N` bits, where `N` is between 1 and 257 | `int32`, `int257`, `int7`      |
| Unsigned `uintN` | 0 to 2<sup>N</sup>-1                  | `N` bits, where `N` is between 1 and 256 | `uint16`, `uint256`, `uint119` |

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets put <sup> for consistency

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Tolk > Type system > Numbers] Improve article in agreement with styleguide

3 participants