[15/23] qecvt.3: SYNOPSIS: Use 'restrict' in prototypes

Message ID 20210308185331.242176-16-alx.manpages@gmail.com
State New
Headers show
Series
  • man3: SYNOPSIS: Use 'restrict' in prototypes (batch 4)
Related show

Commit Message

naohirot--- via Libc-alpha March 8, 2021, 6:53 p.m.
glibc uses 'restrict' in qecvt(), qfcvt().
Let's use it here too.

.../glibc$ grep_glibc_prototype qecvt
stdlib/stdlib.h:890:
extern char *qecvt (long double __value, int __ndigit,
		    int *__restrict __decpt, int *__restrict __sign)
     __THROW __nonnull ((3, 4)) __wur;
.../glibc$ grep_glibc_prototype qfcvt
stdlib/stdlib.h:893:
extern char *qfcvt (long double __value, int __ndigit,
		    int *__restrict __decpt, int *__restrict __sign)
     __THROW __nonnull ((3, 4)) __wur;
.../glibc$

Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>

---
 man3/qecvt.3 | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

-- 
2.30.1

Patch

diff --git a/man3/qecvt.3 b/man3/qecvt.3
index e38922dbf..f904bad54 100644
--- a/man3/qecvt.3
+++ b/man3/qecvt.3
@@ -32,8 +32,12 @@  qecvt, qfcvt, qgcvt \- convert a floating-point number to a string
 .nf
 .B #include <stdlib.h>
 .PP
-.BI "char *qecvt(long double " number ", int " ndigits ", int *" decpt ", int *" sign );
-.BI "char *qfcvt(long double " number ", int " ndigits ", int *" decpt ",i int *" sign );
+.BI "char *qecvt(long double " number ", int " ndigits \
+", int *restrict " decpt ,
+.BI "            int *restrict " sign );
+.BI "char *qfcvt(long double " number ", int " ndigits \
+", int *restrict " decpt ,
+.BI "            int *restrict " sign );
 .BI "char *qgcvt(long double " number ", int " ndigit ", char *" buf );
 .fi
 .PP