From c86f9b3a2dec37c6e9984f81d4630bad343ee452 Mon Sep 17 00:00:00 2001 From: mewmew Date: Wed, 2 Jul 2025 13:27:42 +0200 Subject: [PATCH] Rephrase docs for truncation of float/decimal to integer Use "corresponding integer" instead of "next integer", to avoid confusion that 2.7 may be rounded to 3. --- crates/typst-library/src/foundations/int.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/typst-library/src/foundations/int.rs b/crates/typst-library/src/foundations/int.rs index f65641ff1..a3a073954 100644 --- a/crates/typst-library/src/foundations/int.rs +++ b/crates/typst-library/src/foundations/int.rs @@ -46,7 +46,7 @@ impl i64 { /// or smaller than the minimum 64-bit signed integer. /// /// - Booleans are converted to `0` or `1`. - /// - Floats and decimals are truncated to the next 64-bit integer. + /// - Floats and decimals are truncated to the corresponding 64-bit integer. /// - Strings are parsed in base 10. /// /// ```example