]> git.ipfire.org Git - thirdparty/man-pages.git/blame - man3/putwchar.3
Many pages: Fix style issues reported by `make lint-groff`
[thirdparty/man-pages.git] / man3 / putwchar.3
CommitLineData
fea681da
MK
1.\" Copyright (c) Bruno Haible <haible@clisp.cons.org>
2.\"
e4a74ca8 3.\" SPDX-License-Identifier: GPL-2.0-or-later
fea681da
MK
4.\"
5.\" References consulted:
6.\" GNU glibc-2 source code and manual
7.\" Dinkumware C library reference http://www.dinkumware.com/
008f1ecc 8.\" OpenGroup's Single UNIX specification
fea681da
MK
9.\" http://www.UNIX-systems.org/online.html
10.\" ISO/IEC 9899:1999
11.\"
1d767b55 12.TH PUTWCHAR 3 2021-03-22 "GNU" "Linux Programmer's Manual"
fea681da
MK
13.SH NAME
14putwchar \- write a wide character to standard output
9f4d1e00
AC
15.SH LIBRARY
16Standard C library
8fc3b2cf 17.RI ( libc ", " \-lc )
fea681da
MK
18.SH SYNOPSIS
19.nf
20.B #include <wchar.h>
68e4db0a 21.PP
fea681da
MK
22.BI "wint_t putwchar(wchar_t " wc );
23.fi
24.SH DESCRIPTION
60a90ecd
MK
25The
26.BR putwchar ()
27function is the wide-character equivalent of the
28.BR putchar (3)
29function.
35cfd378
MK
30It writes the wide character
31.I wc
32to
33.IR stdout .
34If
35.I ferror(stdout)
36becomes true, it returns
cab87712 37.BR WEOF .
c13182ef 38If a wide character
35cfd378 39conversion error occurs, it sets
1ae6b2c7 40.I errno
35cfd378
MK
41to
42.B EILSEQ
43and returns
cab87712 44.BR WEOF .
2b9b829d 45Otherwise, it returns
35cfd378 46.IR wc .
fea681da 47.PP
24b74457 48For a nonlocking counterpart, see
fea681da 49.BR unlocked_stdio (3).
47297adb 50.SH RETURN VALUE
60a90ecd
MK
51The
52.BR putwchar ()
35cfd378
MK
53function returns
54.I wc
55if no error occurred, or
cab87712
MK
56.B WEOF
57to indicate an error.
55c039aa
MS
58.SH ATTRIBUTES
59For an explanation of the terms used in this section, see
60.BR attributes (7).
c466875e
MK
61.ad l
62.nh
55c039aa
MS
63.TS
64allbox;
c466875e 65lbx lb lb
55c039aa
MS
66l l l.
67Interface Attribute Value
68T{
69.BR putwchar ()
70T} Thread safety MT-Safe
71.TE
c466875e
MK
72.hy
73.ad
74.sp 1
47297adb 75.SH CONFORMING TO
7cd89de3 76POSIX.1-2001, POSIX.1-2008, C99.
fea681da 77.SH NOTES
d9bfdb9c 78The behavior of
60a90ecd 79.BR putwchar ()
1274071a
MK
80depends on the
81.B LC_CTYPE
82category of the
fea681da
MK
83current locale.
84.PP
60a90ecd
MK
85It is reasonable to expect that
86.BR putwchar ()
87will actually write
35cfd378
MK
88the multibyte sequence corresponding to the wide character
89.IR wc .
47297adb 90.SH SEE ALSO
fea681da
MK
91.BR fputwc (3),
92.BR unlocked_stdio (3)