diff mbox series

[12/22] mbsnrtowcs.3: SYNOPSIS: Use 'restrict' in prototypes

Message ID 20210305235105.177359-13-alx.manpages@gmail.com
State Not Applicable
Headers show
Series man3: SYNOPSIS: Use 'restrict' in prototypes (batch 3) | expand

Commit Message

Alejandro Colomar \(man-pages\) March 5, 2021, 11:50 p.m. UTC
Both POSIX and glibc use 'restrict' in mbsnrtowcs().
Let's use it here too.

.../glibc$ grep_glibc_prototype mbsnrtowcs
wcsmbs/wchar.h:351:
extern size_t mbsnrtowcs (wchar_t *__restrict __dst,
			  const char **__restrict __src, size_t __nmc,
			  size_t __len, mbstate_t *__restrict __ps) __THROW;
.../glibc$

Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
---
 man3/mbsnrtowcs.3 | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/man3/mbsnrtowcs.3 b/man3/mbsnrtowcs.3
index 68b7dc02d..c6428e001 100644
--- a/man3/mbsnrtowcs.3
+++ b/man3/mbsnrtowcs.3
@@ -19,8 +19,9 @@  mbsnrtowcs \- convert a multibyte string to a wide-character string
 .nf
 .B #include <wchar.h>
 .PP
-.BI "size_t mbsnrtowcs(wchar_t *" dest ", const char **" src ,
-.BI "                  size_t " nms ", size_t " len ", mbstate_t *" ps );
+.BI "size_t mbsnrtowcs(wchar_t *restrict " dest ", const char **restrict " src ,
+.BI "                  size_t " nms ", size_t " len \
+", mbstate_t *restrict " ps );
 .fi
 .PP
 .RS -4