Skip to content

Commit

Permalink
decimal: fix tables formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
eapenkin authored Dec 18, 2023
2 parents 7f51009 + cf650de commit 38b0a97
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 16 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## [0.1.19] - 2023-12-18

### Changed

- Improved table formatting in documentation.

## [0.1.18] - 2023-12-18

### Changed
Expand Down
32 changes: 16 additions & 16 deletions doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@ scales and coefficients.
The range of a decimal is determined by its scale.
Here are the ranges for frequently used scales:
| Example | Scale | Minimum | Maximum |
| ------------ | ----- | ------------------------------------ | ----------------------------------- |
| Japanese Yen | 0 | -9,999,999,999,999,999,999 | 9,999,999,999,999,999,999 |
| US Dollar | 2 | -99,999,999,999,999,999.99 | 99,999,999,999,999,999.99 |
| Omani Rial | 3 | -9,999,999,999,999,999.999 | 9,999,999,999,999,999.999 |
| Bitcoin | 8 | -99,999,999,999.99999999 | 99,999,999,999.99999999 |
| Etherium | 9 | -9,999,999,999.999999999 | 9,999,999,999.999999999 |
| Example | Scale | Minimum | Maximum |
| ------------ | ----- | ------------------------------------ | ----------------------------------- |
| Japanese Yen | 0 | -9,999,999,999,999,999,999 | 9,999,999,999,999,999,999 |
| US Dollar | 2 | -99,999,999,999,999,999.99 | 99,999,999,999,999,999.99 |
| Omani Rial | 3 | -9,999,999,999,999,999.999 | 9,999,999,999,999,999.999 |
| Bitcoin | 8 | -99,999,999,999.99999999 | 99,999,999,999.99999999 |
| Etherium | 9 | -9,999,999,999.999999999 | 9,999,999,999.999999999 |
Subnormal numbers are not supported to ensure peak performance.
Consequently, decimals between -0.00000000000000000005 and 0.00000000000000000005
Expand Down Expand Up @@ -99,15 +99,15 @@ an explicit context.
Instead, the context is implicit and can be approximately equated to
the following settings:
| Attribute | Value |
| ----------------------- | ----------------------------------------------- |
| Precision | 19 |
| Maximum Exponent (Emax) | 18 |
| Minimum Exponent (Emin) | -19 |
| Tiny Exponent (Etiny) | -19 |
| Rounding Method | Half To Even |
| Enabled Traps | Division by Zero, Invalid Operation, Overflow |
| Disabled Traps | Inexact, Clamped, Rounded, Subnormal, Underflow |
| Attribute | Value |
| ----------------------- | ----------------------------------------------- |
| Precision | 19 |
| Maximum Exponent (Emax) | 18 |
| Minimum Exponent (Emin) | -19 |
| Tiny Exponent (Etiny) | -19 |
| Rounding Method | Half To Even |
| Enabled Traps | Division by Zero, Invalid Operation, Overflow |
| Disabled Traps | Inexact, Clamped, Rounded, Subnormal, Underflow |
The equality of Etiny and Emin implies that this package does not support
subnormal numbers.
Expand Down

0 comments on commit 38b0a97

Please sign in to comment.