Thread (2 messages) 2 messages, 2 authors, 2019-09-13

[PATCH] printf.3: Add detail on the first digit with the %e format

From: Vincent Lefevre <hidden>
Date: 2019-08-20 13:40:14
Subsystem: the rest · Maintainer: Linus Torvalds

This requirement on the first digit with the %e format comes from
the ISO C standard. It ensures that all the digits in the output are
significant and forbids output with a precision less than requested.

Signed-off-by: Vincent Lefevre <redacted>
---
 man3/printf.3 | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/man3/printf.3 b/man3/printf.3
index fb40b7077..66ad6af02 100644
--- a/man3/printf.3
+++ b/man3/printf.3
@@ -658,7 +658,8 @@ The
 .I double
 argument is rounded and converted in the style
 .RB [\-]d \&. ddd e \(+-dd
-where there is one digit before the decimal-point character and the number
+where there is one digit (which is nonzero if the argument is nonzero)
+before the decimal-point character and the number
 of digits after it is equal to the precision; if the precision is missing,
 it is taken as 6; if the precision is zero, no decimal-point character
 appears.
-- 
2.23.0.rc1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help