aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Lipstate <Jon@Lipstate.com>2023-04-06 09:56:27 -0700
committerJon Lipstate <Jon@Lipstate.com>2023-04-06 09:56:27 -0700
commit846c0f7cfc20ee67db96eb51b0ede431e2bece9b (patch)
treeebd94852300eaf84d700984dcfccb57428d8e736
parent1886193c6cc691e6c8d7ea1f06c81da160ce27ff (diff)
add decimal subpackage ref
-rw-r--r--core/strconv/decimal/decimal.odin8
1 files changed, 4 insertions, 4 deletions
diff --git a/core/strconv/decimal/decimal.odin b/core/strconv/decimal/decimal.odin
index 9e8792813..8884d9138 100644
--- a/core/strconv/decimal/decimal.odin
+++ b/core/strconv/decimal/decimal.odin
@@ -501,7 +501,7 @@ Example:
import "core:fmt"
import "core:strconv"
- strconv_round_down_example :: proc() {
+ round_down_example :: proc() {
d: decimal.Decimal
str := [64]u8{}
ok := decimal.set(&d, "123.456")
@@ -532,9 +532,9 @@ WARNING: There are no guarantees about overflow.
Example:
import "core:fmt"
- import "core:strconv"
- strconv_rounded_integer_example :: proc() {
- d: decimal.Decimal
+ import "core:strconv/decimal"
+ rounded_integer_example :: proc() {
+ d: decimal.Decimal
ok := decimal.set(&d, "123.456")
fmt.println(decimal.rounded_integer(&d))
}