Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc Clean up the NAME section.



details:   https://anonhg.NetBSD.org/src/rev/c9d8b843d1d4
branches:  trunk
changeset: 353254:c9d8b843d1d4
user:      abhinav <abhinav%NetBSD.org@localhost>
date:      Wed Apr 26 07:40:09 2017 +0000

description:
Clean up the NAME section.

The entries in the NAME section of these man pages have man pages of their
own, so it doesn't make sense to have their names here, instead they
should be just described in the body (similar to what we do in math(3) man page).

This also helps whatis(1) and apropos(1), as otherwise you would see multiple
results with the same name in the output, while there is actually only one page
with that name.

Good example is:

$ apropos -n 2 -M realloc
realloc (3)       general memory allocation operations
realloc (3)       general purpose memory allocation functions

The first line is there because memory(3) man page had realloc in its
NAME section. This commit will fix this issue.

ok wiz@

diffstat:

 lib/libc/stdlib/memory.3 |  10 +++-------
 lib/libc/string/string.3 |  36 +++---------------------------------
 2 files changed, 6 insertions(+), 40 deletions(-)

diffs (77 lines):

diff -r 98f1f72fb7f6 -r c9d8b843d1d4 lib/libc/stdlib/memory.3
--- a/lib/libc/stdlib/memory.3  Wed Apr 26 07:17:38 2017 +0000
+++ b/lib/libc/stdlib/memory.3  Wed Apr 26 07:40:09 2017 +0000
@@ -1,4 +1,4 @@
-.\"    $NetBSD: memory.3,v 1.11 2011/09/11 10:05:23 jruoho Exp $
+.\"    $NetBSD: memory.3,v 1.12 2017/04/26 07:40:09 abhinav Exp $
 .\"
 .\" Copyright (c) 1991, 1993
 .\"    The Regents of the University of California.  All rights reserved.
@@ -29,15 +29,11 @@
 .\"
 .\"     from: @(#)memory.3     8.1 (Berkeley) 6/4/93
 .\"
-.Dd September 11, 2011
+.Dd April 26, 2017
 .Dt MEMORY 3
 .Os
 .Sh NAME
-.Nm malloc ,
-.Nm free ,
-.Nm realloc ,
-.Nm calloc ,
-.Nm alloca
+.Nm memory
 .Nd general memory allocation operations
 .Sh LIBRARY
 .Lb libc
diff -r 98f1f72fb7f6 -r c9d8b843d1d4 lib/libc/string/string.3
--- a/lib/libc/string/string.3  Wed Apr 26 07:17:38 2017 +0000
+++ b/lib/libc/string/string.3  Wed Apr 26 07:40:09 2017 +0000
@@ -28,43 +28,13 @@
 .\" SUCH DAMAGE.
 .\"
 .\"     from: @(#)string.3     8.2 (Berkeley) 12/11/93
-.\"    $NetBSD: string.3,v 1.17 2016/07/14 18:36:57 abhinav Exp $
+.\"    $NetBSD: string.3,v 1.18 2017/04/26 07:40:09 abhinav Exp $
 .\"
-.Dd May 1, 2009
+.Dd April 26, 2017
 .Dt STRING 3
 .Os
 .Sh NAME
-.Nm stpcpy ,
-.Nm stpncpy ,
-.Nm strcat ,
-.Nm strlcat ,
-.Nm strncat ,
-.Nm strchr ,
-.Nm strrchr ,
-.Nm strcmp ,
-.Nm strncmp ,
-.Nm strcasecmp ,
-.Nm strncasecmp ,
-.Nm strcoll ,
-.Nm strcpy ,
-.Nm strlcpy ,
-.Nm strncpy ,
-.Nm strerror ,
-.Nm strerror_r ,
-.Nm strlen ,
-.Nm strnlen ,
-.Nm strpbrk ,
-.Nm strsep ,
-.Nm stresep ,
-.Nm strspn ,
-.Nm strcspn ,
-.Nm strdup ,
-.Nm strndup ,
-.Nm strstr ,
-.Nm strcasestr ,
-.Nm strtok ,
-.Nm strtok_r ,
-.Nm strxfrm
+.Nm string
 .Nd string specific functions
 .Sh LIBRARY
 .Lb libc



Home | Main Index | Thread Index | Old Index