[PATCH 16/24] string.3: SYNOPSIS: Use 'restrict' in prototypes

Alejandro Colomar alx.manpages@gmail.com
Wed Mar 10 18:31:42 GMT 2021


glibc uses 'restrict' in strsep().
Let's use it here too.

.../glibc$ grep_glibc_prototype strsep
string/string.h:455:
extern char *strsep (char **__restrict __stringp,
		     const char *__restrict __delim)
     __THROW __nonnull ((1, 2));
.../glibc$

Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
---
 man3/string.3 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/man3/string.3 b/man3/string.3
index 06da21c28..4bacd8d8b 100644
--- a/man3/string.3
+++ b/man3/string.3
@@ -171,7 +171,7 @@ Return a pointer to the last occurrence of the character
 in the string
 .IR s .
 .TP
-.BI "char *strsep(char **" stringp ", const char *" delim );
+.BI "char *strsep(char **restrict " stringp ", const char *restrict " delim );
 Extract the initial token in
 .I stringp
 that is delimited by one of the bytes in
-- 
2.30.1.721.g45526154a5



More information about the Libc-alpha mailing list