summaryrefslogtreecommitdiff
path: root/usr/src/man/man3c
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2014-08-14 15:41:06 -0700
committerGarrett D'Amore <garrett@damore.org>2014-11-04 01:02:21 -0800
commitf07f0fb66492a2792d4da5e0a6f9a92b4c581ab3 (patch)
treec4c3ad54d2abbbd8eb9162d43ed7593f536fde55 /usr/src/man/man3c
parentacd07c6b871cfa70bc42c9278037a17c430897b6 (diff)
downloadillumos-joyent-f07f0fb66492a2792d4da5e0a6f9a92b4c581ab3.tar.gz
5041 man pages needed for some wide character routines
Reviewed by: Rich Ercolani <rercola@pha.jhu.edu> Reviewed by: Igor Kozhukhov <ikozhukhov@gmail.com> Approved by: Robert Mustacchi <rm@joyent.com>
Diffstat (limited to 'usr/src/man/man3c')
-rw-r--r--usr/src/man/man3c/Makefile19
-rw-r--r--usr/src/man/man3c/wcpcpy.3c116
-rw-r--r--usr/src/man/man3c/wcscasecmp.3c158
-rw-r--r--usr/src/man/man3c/wcsdup.3c73
-rw-r--r--usr/src/man/man3c/wcslen.3c94
-rw-r--r--usr/src/man/man3c/wcstring.3c54
6 files changed, 474 insertions, 40 deletions
diff --git a/usr/src/man/man3c/Makefile b/usr/src/man/man3c/Makefile
index 5132755460..8dbc5e4c7c 100644
--- a/usr/src/man/man3c/Makefile
+++ b/usr/src/man/man3c/Makefile
@@ -491,8 +491,12 @@ MANFILES= __fbufsize.3c \
wait3.3c \
waitpid.3c \
walkcontext.3c \
+ wcpcpy.3c \
wcrtomb.3c \
+ wcscasecmp.3c \
wcscoll.3c \
+ wcsdup.3c \
+ wcslen.3c \
wcsftime.3c \
wcsrtombs.3c \
wcsstr.3c \
@@ -1230,7 +1234,9 @@ MANLINKS= FD_CLR.3c \
watoi.3c \
watol.3c \
watoll.3c \
+ wcpncpy.3c \
wcrtomb_l.3c \
+ wcscasecmp_l.3c \
wcscat.3c \
wcschr.3c \
wcscmp.3c \
@@ -1238,10 +1244,12 @@ MANLINKS= FD_CLR.3c \
wcscpy.3c \
wcscspn.3c \
wcsetno.3c \
- wcslen.3c \
+ wcsncasecmp.3c \
+ wcsncasecmp_l.3c \
wcsncat.3c \
wcsncmp.3c \
wcsncpy.3c \
+ wcsnlen.3c \
wcsnrtombs.3c \
wcsnrtombs_l.3c \
wcspbrk.3c \
@@ -2224,11 +2232,19 @@ backtrace_symbols.3c := LINKSRC = walkcontext.3c
backtrace_symbols_fd.3c := LINKSRC = walkcontext.3c
printstack.3c := LINKSRC = walkcontext.3c
+wcpncpy.3c := LINKSRC = wcpcpy.3c
+
wcrtomb_l.3c := LINKSRC = wcrtomb.3c
+wcscasecmp_l.3c := LINKSRC = wcscasecmp.3c
+wcsncasecmp.3c := LINKSRC = wcscasecmp.3c
+wcsncasecmp_l.3c := LINKSRC = wcscasecmp.3c
+
wcscoll_l.3c := LINKSRC = wcscoll.3c
wscoll.3c := LINKSRC = wcscoll.3c
+wcsnlen.3c := LINKSRC = wcslen.3c
+
wcsnrtombs.3c := LINKSRC = wcsrtombs.3c
wcsnrtombs_l.3c := LINKSRC = wcsrtombs.3c
wcsrtombs_l.3c := LINKSRC = wcsrtombs.3c
@@ -2253,7 +2269,6 @@ wcschr.3c := LINKSRC = wcstring.3c
wcscmp.3c := LINKSRC = wcstring.3c
wcscpy.3c := LINKSRC = wcstring.3c
wcscspn.3c := LINKSRC = wcstring.3c
-wcslen.3c := LINKSRC = wcstring.3c
wcsncat.3c := LINKSRC = wcstring.3c
wcsncmp.3c := LINKSRC = wcstring.3c
wcsncpy.3c := LINKSRC = wcstring.3c
diff --git a/usr/src/man/man3c/wcpcpy.3c b/usr/src/man/man3c/wcpcpy.3c
new file mode 100644
index 0000000000..b4a5ecad8e
--- /dev/null
+++ b/usr/src/man/man3c/wcpcpy.3c
@@ -0,0 +1,116 @@
+.\"
+.\" This file and its contents are supplied under the terms of the
+.\" Common Development and Distribution License ("CDDL"), version 1.0.
+.\" You may only use this file in accordance with the terms of version
+.\" 1.0 of the CDDL.
+.\"
+.\" A full copy of the text of the CDDL should have accompanied this
+.\" source. A copy of the CDDL is also available via the Internet at
+.\" http://www.illumos.org/license/CDDL.
+.\"
+.\"
+.\" Copyright 2014 Garrett D'Amore <garrett@damore.org>
+.\"
+.Dd "Jul 27, 2014"
+.Dt WCPCPY 3C
+.Os
+.Sh NAME
+.Nm wcpcpy ,
+.Nm wcpncpy
+.Nd copy a wide-character string and return a pointer to its end
+.Sh SYNOPSIS
+.In wchar.h
+.
+.Ft "wchar_t *"
+.Fo wcpcpy
+.Fa "wchar_t *restrict ws1"
+.Fa "const wchar_t *restrict ws2"
+.Fc
+.
+.Ft "wchar_t *"
+.Fo wcpncpy
+.Fa "wchar_t *restrict ws1"
+.Fa "const wchar_t *restrict ws2"
+.Fa "size_t n"
+.Fc
+.
+.Sh DESCRIPTION
+The
+.Fn wcpcpy
+and
+.Fn wcpncpy
+functions copy the wide-character string pointed to by
+.Fa ws2
+into the location pointed to by
+.Fa ws1 .
+They stop copying after a null wide-character is copied, or in the case
+of
+.Fn wcpncpy ,
+after
+.Fa n
+wide-characters have been copied. If
+.Fa ws2
+contains fewer than
+.Fa n
+wide-characters, then the
+.Fn wcpncpy
+function pads wide-characters to the end of the destination
+.Fa ws1
+until exactly
+.Fa n
+wide-characters have been written.
+.Lp
+In the case of
+.Fn wcpncpy
+a terminating null wide-character will
+.Em not
+be written if the length of
+.Fa ws2
+exceeds
+.Fa n .
+.Lp
+If
+.Fa ws1
+and
+.Fa ws2
+overlap, the result is undefined.
+.Lp
+The
+.Fn wcpcpy
+and
+.Fn wcpncpy
+functions are the wide-character equivalents of
+.Fn stpcpy
+and
+.Fn stpncpy ,
+respectively.
+.Sh RETURN VALUES
+The
+.Fn wcpcpy
+and
+.Fn wcpncpy
+functions return a pointer to the last wide-character written. In the
+case of
+.Fn wcpncpy
+this will always be equal to
+.Po Fa ws1 Li + Fa n Li \(mi 1 Pc .
+.Sh ERRORS
+None.
+.Sh INTERFACE STABILITY
+.Sy Standard .
+.Sh MT-LEVEL
+.Sy MT-Safe .
+.Sh SEE ALSO
+.Xr stpcpy 3C ,
+.Xr stpncpy 3C ,
+.Xr wcscpy 3C ,
+.Xr wcsncpy 3C ,
+.Xr wchar.h 3HEAD ,
+.Xr standards 5
+.Sh STANDARDS
+The
+.Fn wcpcpy
+and
+.Fn wcpncpy
+functions were introduced in
+.St -p1003.1-2008 .
diff --git a/usr/src/man/man3c/wcscasecmp.3c b/usr/src/man/man3c/wcscasecmp.3c
new file mode 100644
index 0000000000..6a6aca9922
--- /dev/null
+++ b/usr/src/man/man3c/wcscasecmp.3c
@@ -0,0 +1,158 @@
+.\"
+.\" This file and its contents are supplied under the terms of the
+.\" Common Development and Distribution License ("CDDL"), version 1.0.
+.\" You may only use this file in accordance with the terms of version
+.\" 1.0 of the CDDL.
+.\"
+.\" A full copy of the text of the CDDL should have accompanied this
+.\" source. A copy of the CDDL is also available via the Internet at
+.\" http://www.illumos.org/license/CDDL.
+.\"
+.\"
+.\" Copyright 2014 Garrett D'Amore <garrett@damore.org>
+.\"
+.Dd "Nov 4, 2014"
+.Dt WCSCASECMP 3C
+.Os
+.Sh NAME
+.Nm wcscasecmp ,
+.Nm wcscasecmp_l ,
+.Nm wcsncasecmp ,
+.Nm wcsncasecmp_l
+.Nd case-insensitive wide-character string comparison
+.Sh SYNOPSIS
+.In wchar.h
+.
+.Ft int
+.Fo wcscasecmp
+.Fa "const wchar_t *ws1"
+.Fa "const wchar_t *ws2"
+.Fc
+.
+.Ft int
+.Fo wcscasecmp_l
+.Fa "const wchar_t *ws1"
+.Fa "const wchar_t *ws2"
+.Fa "locale_t loc"
+.Fc
+.
+.Ft int
+.Fo wcsncasecmp
+.Fa "const wchar_t *ws1"
+.Fa "const wchar_t *ws2"
+.Fa "size_t n"
+.Fc
+.
+.Ft int
+.Fo wcsncasecmp_l
+.Fa "const wchar_t *ws1"
+.Fa "const wchar_t *ws2"
+.Fa "size_t n"
+.Fa "locale_t loc"
+.Fc
+.Sh DESCRIPTION
+These functions perform case-insensitive comparison of wide-character
+strings
+.Fa ws1
+and
+.Fa ws2 .
+Pairs of wide-characters from each of
+.Fa ws1
+and
+.Fa ws2
+are compared consecutively, ignoring differences in case (if the
+.\"POSIX\." locale upper case characters are treated as lower case). If
+the two values are different, the comparision stops and either
+a negative value is returned if the character from
+.Fa ws1
+is less than that from
+.Fa ws2 ,
+or a positive is returned if the character from
+.Fa ws1
+is greater than that from
+.Fa ws2 .
+The comparison also stops if both characters are null wide-characters,
+or, in the case of
+.Fn wcsncasecmp
+and
+.Fn wcsncasecmp_l ,
+after
+.Fa n
+comparisons have been made without finding a difference. In either of
+these two cases, 0 is returned.
+.Lp
+The
+.Fn wcscasecmp
+and
+.Fn wcsncasecmp
+functions use the
+.Dv LC_CTYPE
+category of the current locale to determine case. The
+.Fn wcscasecmp_l
+and
+.Fn wcsncasecmp_l
+functions use the
+.Dv LC_CTYPE
+category of the locale pointed to by
+.Fa loc
+to determine case.
+.Lp
+Passing
+.Dv LC_GLOBAL_LOCALE
+for
+.Fa loc
+results in undefined behavior.
+.Lp
+The
+.Fn wcscasecmp ,
+.Fn wcsncasecmp ,
+.Fn wcscasecmp_l ,
+and
+.Fn wcsncasecmp_l
+functions are the wide-character equivalents of the
+.Fn strcasecmp ,
+.Fn strncasecmp ,
+.Fn strcasemp_l ,
+and
+.Fn strncasecmp_l
+functions, respectively.
+.Sh RETURN VALUES
+These functions return a negative value if, ignoring case,
+.Fa ws1
+is less than
+.Fa ws1 ,
+or a positive value if
+.Fa ws1
+is greater than
+.Fa ws2 ,
+or 0 if the both
+.Fa ws1
+and
+.Fa ws2
+are the same.
+.Sh ERRORS
+None.
+.Sh INTERFACE STABILITY
+.Sy Standard .
+.Sh MT-LEVEL
+.Sy MT-Safe .
+.Sh SEE ALSO
+.Xr newlocale 3C ,
+.Xr setlocale 3C ,
+.Xr strcasecmp 3C ,
+.Xr strcasecmp_l 3C ,
+.Xr strncasecmp 3C ,
+.Xr strncasecmp_l 3C ,
+.Xr uselocale 3C ,
+.Xr wchar.h 3HEAD ,
+.Xr locale 5 ,
+.Xr standards 5
+.Sh STANDARDS
+The
+.Fn wcscasecmp ,
+.Fn wcsncasecmp ,
+.Fn wcscasecmp_l ,
+and
+.Fn wcsncasecmp_l
+functions were introduced in
+.St -p1003.1-2008 .
diff --git a/usr/src/man/man3c/wcsdup.3c b/usr/src/man/man3c/wcsdup.3c
new file mode 100644
index 0000000000..80113744a9
--- /dev/null
+++ b/usr/src/man/man3c/wcsdup.3c
@@ -0,0 +1,73 @@
+.\"
+.\" This file and its contents are supplied under the terms of the
+.\" Common Development and Distribution License ("CDDL"), version 1.0.
+.\" You may only use this file in accordance with the terms of version
+.\" 1.0 of the CDDL.
+.\"
+.\" A full copy of the text of the CDDL should have accompanied this
+.\" source. A copy of the CDDL is also available via the Internet at
+.\" http://www.illumos.org/license/CDDL.
+.\"
+.\"
+.\" Copyright 2014 Garrett D'Amore <garrett@damore.org>
+.\"
+.Dd "Nov 4, 2014"
+.Dt WCSDUP 3C
+.Os
+.Sh NAME
+.Nm wcsdup
+.Nd duplicate wide-character string
+.Sh SYNOPSIS
+.In wchar.h
+.
+.Ft wchar_t
+.Fo wcsdup
+.Fa "const wchar_t *string"
+.Fc
+.
+.Sh DESCRIPTION
+The
+.Fn wcsdup
+function duplicates a wide-character
+.Fa string ,
+allocating sufficient memory to store the copy, and then
+copying from
+.Fa string .
+The resulting copy is returned. It may be deallocated with
+.Xr free 3C
+when it is no longer needed. The
+.Fn wcsdup
+function is the wide-character equivalent of
+.Xr strdup 3C .
+.Sh RETURN VALUES
+On success, the function
+.Fn wcsdup
+returns the newly allocated copy of the string; on failure it
+returns
+.Dv NULL
+and sets
+.Va errno .
+.Sh ERRORS
+The
+.Fn wcsdup
+function will fail if:
+.Bl -tag -width Er
+.It Er ENOMEM
+Insufficient memory was available to create the copy.
+.El
+.Sh INTERFACE STABILITY
+.Sy Standard .
+.Sh MT-LEVEL
+.Sy MT-Safe .
+.Sh SEE ALSO
+.Xr free 3C ,
+.Xr strdup 3C ,
+.Xr wcslen 3C ,
+.Xr wchar.h 3HEAD ,
+.Xr locale 5 ,
+.Xr standards 5
+.Sh STANDARDS
+The
+.Fn wcsdup
+function was introduced in
+.St -p1003.1-2008 .
diff --git a/usr/src/man/man3c/wcslen.3c b/usr/src/man/man3c/wcslen.3c
new file mode 100644
index 0000000000..71a4bde897
--- /dev/null
+++ b/usr/src/man/man3c/wcslen.3c
@@ -0,0 +1,94 @@
+.\"
+.\" This file and its contents are supplied under the terms of the
+.\" Common Development and Distribution License ("CDDL"), version 1.0.
+.\" You may only use this file in accordance with the terms of version
+.\" 1.0 of the CDDL.
+.\"
+.\" A full copy of the text of the CDDL should have accompanied this
+.\" source. A copy of the CDDL is also available via the Internet at
+.\" http://www.illumos.org/license/CDDL.
+.\"
+.\"
+.\" Copyright 2014 Garrett D'Amore <garrett@damore.org>
+.\"
+.Dd "Nov 4, 2014"
+.Dt WCSLEN 3C
+.Os
+.Sh NAME
+.Nm wcslen ,
+.Nm wcsnlen
+.Nd get length of wide-character string
+.Sh SYNOPSIS
+.In wchar.h
+.
+.Ft size_t
+.Fo wcslen
+.Fa "const wchar_t *string"
+.Fc
+.
+.Ft size_t
+.Fo wcsnlen
+.Fa "const wchar_t *string"
+.Fa "size_t maxlen"
+.Fc
+.
+.Sh DESCRIPTION
+The
+.Fn wcslen
+and
+.Fn wcsnlen
+functions count the number of wide-characters that are present in
+.Fa string .
+They stop counting when they encounter a null wide-character.
+The terminating null wide-character is not included in the count.
+.Lp
+Additionally,
+.Fn wcsnlen
+stops counting after it has counted
+.Fa maxlen
+wide-characters.
+.Lp
+The
+.Fn wcslen
+and
+.Fn wcsnlen
+functions are the wide-character equivalents of
+.Xr strlen 3C
+and
+.Xr strnlen 3C ,
+respectively.
+.Sh RETURN VALUES
+The
+.Fn wcslen
+function returns the length of
+.Fa string .
+The
+.Fn wcsnlen
+function returns the smaller of the length of
+.Fa string
+and
+.Fa maxlen .
+.Sh ERRORS
+None.
+.Sh INTERFACE STABILITY
+.Sy Standard .
+.Sh MT-LEVEL
+.Sy MT-Safe .
+.Sh SEE ALSO
+.Xr free 3C ,
+.Xr strlen 3C ,
+.Xr strnlen 3C ,
+.Xr wchar.h 3HEAD ,
+.Xr locale 5 ,
+.Xr standards 5
+.Sh STANDARDS
+The
+.Fn wcslen
+function was introduced in
+.St -xpg4
+and standardized in
+.St -isoC-99 .
+The
+.Fn wcsnlen
+function was introduced in
+.St -p1003.1-2008 .
diff --git a/usr/src/man/man3c/wcstring.3c b/usr/src/man/man3c/wcstring.3c
index 72a3098f9b..d4d3f3e953 100644
--- a/usr/src/man/man3c/wcstring.3c
+++ b/usr/src/man/man3c/wcstring.3c
@@ -1,4 +1,5 @@
'\" te
+.\" Copyright 2014 Garrett D'Amore <garrett@damore.org>
.\" Copyright (c) 1992, X/Open Company Limited All Rights Reserved Portions Copyright (c) 2002, Sun Microsystems, Inc. All Rights Reserved
.\" Sun Microsystems, Inc. gratefully acknowledges The Open Group for permission to reproduce portions of its copyrighted documentation. Original documentation from The Open Group can be obtained online at
.\" http://www.opengroup.org/bookstore/.
@@ -7,10 +8,10 @@
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
-.TH WCSTRING 3C "Aug 14, 2002"
+.TH WCSTRING 3C "Aug 15, 2014"
.SH NAME
wcstring, wcscat, wscat, wcsncat, wsncat, wcscmp, wscmp, wcsncmp, wsncmp,
-wcscpy, wscpy, wcsncpy, wsncpy, wcslen, wslen, wcschr, wschr, wcsrchr, wsrchr,
+wcscpy, wscpy, wcsncpy, wsncpy, wslen, wcschr, wschr, wcsrchr, wsrchr,
windex, wrindex, wcspbrk, wspbrk, wcswcs, wcsspn, wsspn, wcscspn, wscspn,
wcstok, wstok \- wide-character string operations
.SH SYNOPSIS
@@ -50,11 +51,6 @@ wcstok, wstok \- wide-character string operations
.LP
.nf
-\fBsize_t\fR \fBwcslen\fR(\fBconst wchar_t *\fR\fIws\fR);
-.fi
-
-.LP
-.nf
\fBwchar_t *\fR\fBwcschr\fR(\fBconst wchar_t *\fR\fIws\fR, \fBwchar_t\fR \fIwc\fR);
.fi
@@ -208,7 +204,6 @@ wcstok, wstok \- wide-character string operations
.fi
.SH DESCRIPTION
-.sp
.LP
These functions operate on wide-character strings terminated by \fBwchar_t\fR
\fINULL\fR characters. During appending or copying, these routines do not check
@@ -216,7 +211,6 @@ for an overflow condition of the receiving string. In the following, \fIws\fR,
\fIws1\fR, and \fIws2\fR point to wide-character strings terminated by a
\fBwchar_t NULL\fR.
.SS "wcscat(\|), wscat(\|)"
-.sp
.LP
The \fBwcscat()\fR and \fBwscat()\fR functions append a copy of the
wide-character string pointed to by \fIws2\fR (including the terminating null
@@ -226,7 +220,6 @@ wide-character code at the end of \fIws1\fR. If copying takes place between
objects that overlap, the behavior is undefined. Both functions return
\fIs1\fR; no return value is reserved to indicate an error.
.SS "wcsncat(\|), wsncat(\|)"
-.sp
.LP
The \fBwcsncat()\fR and \fBwsncat()\fR functions append not more than \fIn\fR
wide-character codes (a null wide-character code and wide-character codes that
@@ -237,7 +230,6 @@ end of \fIws1\fR. A terminating null wide-character code is always appended to
the result. Both functions return \fIws1\fR; no return value is reserved to
indicate an error.
.SS "wcscmp(\|), wscmp(\|)"
-.sp
.LP
The \fBwcscmp()\fR and \fBwscmp()\fR functions compare the wide-character
string pointed to by \fIws1\fR to the wide-character string pointed to by
@@ -248,7 +240,6 @@ integer greater than, equal to, or less than zero, if the wide-character string
pointed to by \fIws1\fR is greater than, equal to, or less than the
wide-character string pointed to by \fIws2\fR.
.SS "wcsncmp(\|), wsncmp(\|)"
-.sp
.LP
The \fBwcsncmp()\fR and \fBwsncmp()\fR functions compare not more than \fIn\fR
wide-character codes (wide-character codes that follow a null wide character
@@ -261,7 +252,6 @@ than zero, if the possibly null-terminated array pointed to by \fIws1\fR is
greater than, equal to, or less than the possibly null-terminated array pointed
to by \fIws2\fR.
.SS "wcscpy(\|), wscpy(\|)"
-.sp
.LP
The \fBwcscpy()\fR and \fBwscpy()\fR functions copy the wide-character string
pointed to by \fIws2\fR (including the terminating null wide-character code)
@@ -269,7 +259,6 @@ into the array pointed to by \fIws1\fR. If copying takes place between objects
that overlap, the behavior is undefined. Both functions return \fIws1\fR; no
return value is reserved to indicate an error.
.SS "wcsncpy(\|), wsncpy(\|)"
-.sp
.LP
The \fBwcsncpy()\fR and \fBwsncpy()\fR functions copy not more than \fIn\fR
wide-character codes (wide-character codes that follow a null wide character
@@ -280,15 +269,13 @@ wide-character string that is shorter than \fIn\fR wide-character codes, null
wide-character codes are appended to the copy in the array pointed to by
\fIws1\fR, until a total \fIn\fR wide-character codes are written. Both
functions return \fI ws1\fR; no return value is reserved to indicate an error.
-.SS "wcslen(\|), wslen(\|)"
-.sp
+.SS "wslen(\|)"
.LP
-The \fBwcslen()\fR and \fBwslen()\fR functions compute the number of
+The \fBwslen()\fR function computes the number of
wide-character codes in the wide-character string to which \fIws\fR points, not
-including the terminating null wide-character code. Both functions return
+including the terminating null wide-character code. It returns
\fIws\fR; no return value is reserved to indicate an error.
.SS "wcschr(\|), wschr(\|)"
-.sp
.LP
The \fBwcschr()\fR and \fBwschr()\fR functions locate the first occurrence of
\fIwc\fR in the wide-character string pointed to by \fIws\fR. The value of
@@ -298,7 +285,6 @@ The terminating null wide-character code is considered to be part of the
wide-character string. Upon completion, both functions return a pointer to the
wide-character code, or a null pointer if the wide-character code is not found.
.SS "wcsrchr(\|), wsrchr(\|)"
-.sp
.LP
The \fBwcsrchr()\fR and \fBwsrchr()\fR functions locate the last occurrence of
\fIwc\fR in the wide-character string pointed to by \fIws\fR. The value of
@@ -309,12 +295,10 @@ wide-character string. Upon successful completion, both functions return a
pointer to the wide-character code, or a null pointer if \fIwc\fR does not
occur in the wide-character string.
.SS "windex(\|), wrindex(\|)"
-.sp
.LP
The \fBwindex()\fR and \fBwrindex()\fR functions behave the same as
\fBwschr()\fR and \fBwsrchr()\fR, respectively.
.SS "wcspbrk(\|), wspbrk(\|)"
-.sp
.LP
The \fBwcspbrk()\fR and \fBwspbrk()\fR functions locate the first occurrence in
the wide character string pointed to by \fIws1\fR of any wide-character code
@@ -322,7 +306,6 @@ from the wide-character string pointed to by \fIws2\fR. Upon successful
completion, the function returns a pointer to the wide-character code, or a
null pointer if no wide-character code from \fIws2\fR occurs in \fIws1\fR.
.SS "wcswcs(\|)"
-.sp
.LP
The \fBwcswcs()\fR function locates the first occurrence in the wide-character
string pointed to by \fIws1\fR of the sequence of wide-character codes
@@ -332,7 +315,6 @@ returns a pointer to the located wide-character string, or a null pointer if
the wide-character string is not found. If \fIws2\fR points to a wide-character
string with zero length, the function returns \fIws1\fR.
.SS "wcsspn(\|), wsspn(\|)"
-.sp
.LP
The \fBwcsspn()\fR and \fBwsspn()\fR functions compute the length of the
maximum initial segment of the wide-character string pointed to by \fIws1\fR
@@ -340,7 +322,6 @@ which consists entirely of wide-character codes from the wide-character string
pointed to by \fIws2\fR. Both functions return the length \fIws1\fR; no return
value is reserved to indicate an error.
.SS "wcscspn(\|), wscspn(\|)"
-.sp
.LP
The \fBwcscspn()\fR and \fBwscspn()\fR functions compute the length of the
maximum initial segment of the wide-character string pointed to by \fIws1\fR
@@ -349,26 +330,22 @@ wide-character string pointed to by \fIws2\fR. Both functions return the length
of the initial substring of \fIws1\fR; no return value is reserved to indicate
an error.
.SS "wcstok(\|), wstok(\|)"
-.sp
.LP
A sequence of calls to the \fBwcstok()\fR and \fBwstok()\fR functions break the
wide-character string pointed to by \fIws1\fR into a sequence of tokens, each
of which is delimited by a wide-character code from the wide-character string
pointed to by \fIws2\fR.
.SS "Default and other standards"
-.sp
.LP
The third argument points to a caller-provided \fBwchar_t\fR pointer into which
the \fBwcstok()\fR function stores information necessary for it to continue
scanning the same wide-character string. This argument is not available with
the XPG4 and SUS versions of \fBwcstok()\fR, nor is it available with the
\fBwstok()\fR function. See \fBstandards\fR(5).
-.sp
.LP
The first call in the sequence has \fIws1\fR as its first argument, and is
followed by calls with a null pointer as their first argument. The separator
string pointed to by \fIws2\fR may be different from call to call.
-.sp
.LP
The first call in the sequence searches the wide-character string pointed to by
\fIws1\fR for the first wide-character code that is \fInot\fR contained in the
@@ -376,7 +353,6 @@ current separator string pointed to by \fIws2\fR. If no such wide-character
code is found, then there are no tokens in the wide-character string pointed to
by \fIws1\fR, and \fBwcstok()\fR and \fBwstok()\fR return a null pointer. If
such a wide-character code is found, it is the start of the first token.
-.sp
.LP
The \fBwcstok()\fR and \fBwstok()\fR functions then search from that point for
a wide-character code that \fIis\fR contained in the current separator string.
@@ -386,17 +362,14 @@ for a token will return a null pointer. If such a wide-character code is found,
it is overwritten by a null wide character, which terminates the current token.
The \fBwcstok()\fR and \fBwstok()\fR functions save a pointer to the following
wide-character code, from which the next search for a token will start.
-.sp
.LP
Each subsequent call, with a null pointer as the value of the first argument,
starts searching from the saved pointer and behaves as described above.
-.sp
.LP
Upon successful completion, both functions return a pointer to the first
wide-character code of a token. Otherwise, if there is no token, a null pointer
is returned.
.SH ATTRIBUTES
-.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp
@@ -416,15 +389,20 @@ MT-Level MT-Safe
.TE
.SH SEE ALSO
-.sp
.LP
-\fBmalloc\fR(3C), \fBstring\fR(3C), \fBwcswidth\fR(3C), \fBwcwidth\fR(3C),
-\fBattributes\fR(5), \fBstandards\fR(5)
+\fBmalloc\fR(3C),
+\fBstring\fR(3C),
+\fBwcscasecmp\fR(3C),
+\fBwcsdup\fR(3C),
+\fBwcslen\fR(3C),
+\fBwcswidth\fR(3C),
+\fBwcwidth\fR(3C),
+\fBattributes\fR(5),
+\fBstandards\fR(5)
.SH NOTES
-.sp
.LP
The \fBwcscat()\fR, \fBwcsncat()\fR, \fBwcscmp()\fR, \fBwcsncmp()\fR,
-\fBwcscpy()\fR, \fBwcsncpy()\fR, \fBwcslen()\fR, \fBwcschr()\fR,
+\fBwcscpy()\fR, \fBwcsncpy()\fR, \fBwcschr()\fR,
\fBwcsrchr()\fR, \fBwcspbrk()\fR, \fBwcswcs()\fR, \fBwcsspn()\fR,
\fBwcscspn()\fR, and \fBwcstok()\fR functions are Standard. The \fBwscat()\fR,
\fBwsncat()\fR, \fBwscmp()\fR, \fBwsncmp()\fR, \fBwscpy()\fR, \fBwsncpy()\fR,