BSD 4_4 development
[unix-history] / usr / share / man / cat3 / fputc.0
CommitLineData
8bb980a3
C
1PUTC(3) BSD Programmer's Manual PUTC(3)
2
3N\bNA\bAM\bME\bE
4 f\bfp\bpu\but\btc\bc, p\bpu\but\btc\bc, p\bpu\but\btc\bch\bha\bar\br, p\bpu\but\btw\bw - output a character or word to a stream
5
6S\bSY\bYN\bNO\bOP\bPS\bSI\bIS\bS
7 #\b#i\bin\bnc\bcl\blu\bud\bde\be <\b<s\bst\btd\bdi\bio\bo.\b.h\bh>\b>
8
9 _\bi_\bn_\bt
10 f\bfp\bpu\but\btc\bc(_\bi_\bn_\bt _\bc, _\bF_\bI_\bL_\bE _\b*_\bs_\bt_\br_\be_\ba_\bm);
11
12 _\bi_\bn_\bt
13 p\bpu\but\btc\bc(_\bi_\bn_\bt _\bc, _\bF_\bI_\bL_\bE _\b*_\bs_\bt_\br_\be_\ba_\bm);
14
15 _\bi_\bn_\bt
16 p\bpu\but\btc\bch\bha\bar\br(_\bi_\bn_\bt _\bc);
17
18 _\bi_\bn_\bt
19 p\bpu\but\btw\bw(_\bi_\bn_\bt _\bw, _\bF_\bI_\bL_\bE _\b*_\bs_\bt_\br_\be_\ba_\bm);
20
21D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
22 The f\bfp\bpu\but\btc\bc() function writes the character _\bc (converted to an ``unsigned
23 char'') to the output stream pointed to by _\bs_\bt_\br_\be_\ba_\bm.
24
25 P\bPu\but\btc\bc() acts essentially identically to f\bfp\bpu\but\btc\bc(), but is a macro that ex-
26 pands in-line. It may evaluate _\bs_\bt_\br_\be_\ba_\bm more than once, so arguments given
27 to p\bpu\but\btc\bc() should not be expressions with potential side effects.
28
29 P\bPu\but\btc\bch\bha\bar\br() is identical to p\bpu\but\btc\bc() with an output stream of _\bs_\bt_\bd_\bo_\bu_\bt.
30
31 The p\bpu\but\btw\bw() function writes the specified _\bi_\bn_\bt to the named output _\bs_\bt_\br_\be_\ba_\bm.
32
33R\bRE\bET\bTU\bUR\bRN\bN V\bVA\bAL\bLU\bUE\bES\bS
34 The functions, f\bfp\bpu\but\btc\bc(), p\bpu\but\btc\bc() and p\bpu\but\btc\bch\bha\bar\br() return the character writ-
35 ten. If an error occurs, the value EOF is returned. The p\bpu\but\btw\bw() function
36 returns 0 on success; EOF is returned if a write error occurs, or if an
37 attempt is made to write a read-only stream.
38
39S\bSE\bEE\bE A\bAL\bLS\bSO\bO
40 ferror(3), fopen(3), getc(3), stdio(3)
41
42S\bST\bTA\bAN\bND\bDA\bAR\bRD\bDS\bS
43 The functions f\bfp\bpu\but\btc\bc(), p\bpu\but\btc\bc(), and p\bpu\but\btc\bch\bha\bar\br(), conform to ANSI C
44 X3.159-1989 (``ANSI C ''). A function p\bpu\but\btw\bw() function appeared in Version
45 6 AT&T UNIX.
46
47B\bBU\bUG\bGS\bS
48 The size and byte order of an _\bi_\bn_\bt varies from one machine to another, and
49 p\bpu\but\btw\bw() is not recommended for portable applications.
50
514.4BSD June 4, 1993 1