[04/23] pthread_attr_setstacksize.3: SYNOPSIS: Use 'restrict' in prototypes

Message ID 20210308185331.242176-5-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.
Both POSIX and glibc use 'restrict' in pthread_attr_getstacksize().
Let's use it here too.

.../glibc$ grep_glibc_prototype pthread_attr_getstacksize
sysdeps/htl/pthread.h:192:
extern int pthread_attr_getstacksize (const pthread_attr_t *__restrict __attr,
				      size_t *__restrict __stacksize)
	__THROW __nonnull ((1, 2));
sysdeps/nptl/pthread.h:346:
extern int pthread_attr_getstacksize (const pthread_attr_t *__restrict
				      __attr, size_t *__restrict __stacksize)
     __THROW __nonnull ((1, 2));
.../glibc$

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

---
 man3/pthread_attr_setstacksize.3 | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
2.30.1

Patch

diff --git a/man3/pthread_attr_setstacksize.3 b/man3/pthread_attr_setstacksize.3
index 824dbc5f7..e1e56aeee 100644
--- a/man3/pthread_attr_setstacksize.3
+++ b/man3/pthread_attr_setstacksize.3
@@ -33,8 +33,8 @@  attribute in thread attributes object
 .PP
 .BI "int pthread_attr_setstacksize(pthread_attr_t *" attr \
 ", size_t " stacksize );
-.BI "int pthread_attr_getstacksize(const pthread_attr_t *" attr ,
-.BI "                              size_t *" stacksize );
+.BI "int pthread_attr_getstacksize(const pthread_attr_t *restrict " attr ,
+.BI "                              size_t *restrict " stacksize );
 .PP
 Compile and link with \fI\-pthread\fP.
 .fi