[PATCH 1/2] printf(3): improve terminology in %a description

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The term "decimal point" does not technically apply when using bases
other than 10; the more generic term is "radix point".  Update the
description of the a/A conversion specifier (i.e., for hexadecimal
floating point output) in printf(3) to use this terminology.

I do note that POSIX.1-2024 [1] does use the term "decimal-point
character" here, but I still maintain that using "radix point" is a
better term for that object in the %a description.  (Confusingly, POSIX
does refer to "radix character" in the descriptions of %f and %e, where
reference to "decimal" instead of "radix" would actually make sense.)

[1] <https://pubs.opengroup.org/onlinepubs/9799919799/functions/printf.html>

Signed-off-by: Ken Pizzini <ken@xxxxxxx>
---
 man/man3/printf.3 | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/man/man3/printf.3 b/man/man3/printf.3
index 3bc731f6e..7a96ec9c7 100644
--- a/man/man3/printf.3
+++ b/man/man3/printf.3
@@ -759,13 +759,13 @@ .SS Conversion specifiers
 the letters ABCDEF, and the exponent separator
 .B P
 is used.
-There is one hexadecimal digit before the decimal point,
+There is one hexadecimal digit before the radix point,
 and the number of digits after it is equal to the precision.
 The default precision suffices for an exact representation of the value
 if an exact representation in base 2 exists
 and otherwise is sufficiently large to distinguish values of type
 .IR double .
-The digit before the decimal point is unspecified for nonnormalized
+The digit before the radix point is unspecified for nonnormalized
 numbers, and nonzero but otherwise unspecified for normalized numbers.
 The exponent always contains at least one
 digit; if the value is zero, the exponent is 0.
-- 
2.47.0




[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux