]> git.saurik.com Git - apple/libc.git/blobdiff - stdio/ungetc.3
Libc-594.9.5.tar.gz
[apple/libc.git] / stdio / ungetc.3
index adb91fa0b157837c78f8d869706b79c98aeb059b..3b3f686af9431a0a56394c6c23973f42725d84d5 100644 (file)
@@ -34,7 +34,7 @@
 .\" SUCH DAMAGE.
 .\"
 .\"     @(#)ungetc.3   8.1 (Berkeley) 6/4/93
 .\" SUCH DAMAGE.
 .\"
 .\"     @(#)ungetc.3   8.1 (Berkeley) 6/4/93
-.\" $FreeBSD: src/lib/libc/stdio/ungetc.3,v 1.12 2001/10/01 16:08:59 ru Exp $
+.\" $FreeBSD: src/lib/libc/stdio/ungetc.3,v 1.13 2002/10/10 04:12:40 tjr Exp $
 .\"
 .Dd June 4, 1993
 .Dt UNGETC 3
 .\"
 .Dd June 4, 1993
 .Dt UNGETC 3
 .Sh SYNOPSIS
 .In stdio.h
 .Ft int
 .Sh SYNOPSIS
 .In stdio.h
 .Ft int
-.Fn ungetc "int c" "FILE *stream"
+.Fo ungetc
+.Fa "int c"
+.Fa "FILE *stream"
+.Fc
 .Sh DESCRIPTION
 The
 .Fn ungetc
 .Sh DESCRIPTION
 The
 .Fn ungetc
@@ -56,20 +59,20 @@ function pushes the character
 (converted to an unsigned char)
 back onto the input stream pointed to by
 .Fa stream .
 (converted to an unsigned char)
 back onto the input stream pointed to by
 .Fa stream .
-The pushed-back characters will be returned by subsequent reads on the
-stream (in reverse order).
-A successful intervening call,
-using the same stream,
+The pushed-back characters will be returned (in reverse order)
+by subsequent reads on the stream.
+A successful intervening call
 to one of the file positioning functions
 .Xr ( fseek 3 ,
 .Xr fsetpos 3 ,
 or
 to one of the file positioning functions
 .Xr ( fseek 3 ,
 .Xr fsetpos 3 ,
 or
-.Xr rewind 3 )
-will discard the pushed back characters.
+.Xr rewind 3 ) ,
+using the same stream,
+will discard the pushed-back characters.
 .Pp
 .Pp
-One character of push-back is guaranteed,
+Only one character of push-back is guaranteed,
 but as long as there is sufficient memory,
 but as long as there is sufficient memory,
-an effectively infinite amount of pushback is allowed.
+an effectively infinite amount of push-back is allowed.
 .Pp
 If a character is successfully pushed-back,
 the end-of-file indicator for the stream is cleared.
 .Pp
 If a character is successfully pushed-back,
 the end-of-file indicator for the stream is cleared.
@@ -93,7 +96,8 @@ the operation will fail and the stream will remain unchanged.
 .Sh SEE ALSO
 .Xr fseek 3 ,
 .Xr getc 3 ,
 .Sh SEE ALSO
 .Xr fseek 3 ,
 .Xr getc 3 ,
-.Xr setvbuf 3
+.Xr setvbuf 3 ,
+.Xr ungetwc 3
 .Sh STANDARDS
 The
 .Fn ungetc
 .Sh STANDARDS
 The
 .Fn ungetc