summaryrefslogtreecommitdiffstats
path: root/doc/eof.n
diff options
context:
space:
mode:
Diffstat (limited to 'doc/eof.n')
-rw-r--r--doc/eof.n45
1 files changed, 3 insertions, 42 deletions
diff --git a/doc/eof.n b/doc/eof.n
index 0dcf34a..7eea515 100644
--- a/doc/eof.n
+++ b/doc/eof.n
@@ -16,49 +16,10 @@ eof \- Check for end of file condition on channel
.BE
.SH DESCRIPTION
.PP
-Returns 1 if an end of file condition occurred during the most
-recent input operation on \fIchannelId\fR (such as \fBgets\fR),
-0 otherwise.
-.PP
-\fIChannelId\fR must be an identifier for an open channel such as a
-Tcl standard channel (\fBstdin\fR, \fBstdout\fR, or \fBstderr\fR),
-the return value from an invocation of \fBopen\fR or \fBsocket\fR, or
-the result of a channel creation command provided by a Tcl extension.
-.SH EXAMPLES
-.PP
-Read and print out the contents of a file line-by-line:
-.PP
-.CS
-set f [open somefile.txt]
-while {1} {
- set line [gets $f]
- if {[\fBeof\fR $f]} {
- close $f
- break
- }
- puts "Read line: $line"
-}
-.CE
-.PP
-Read and print out the contents of a file by fixed-size records:
-.PP
-.CS
-set f [open somefile.dat]
-fconfigure $f -translation binary
-set recordSize 40
-while {1} {
- set record [read $f $recordSize]
- if {[\fBeof\fR $f]} {
- close $f
- break
- }
- puts "Read record: $record"
-}
-.CE
+The \fBeof\fR command has been superceded by the \fBchan eof\fR
+command which supports the same syntax and options.
.SH "SEE ALSO"
-file(n), open(n), close(n), fblocked(n), Tcl_StandardChannels(3)
-.SH KEYWORDS
-channel, end of file
+chan(n)
'\" Local Variables:
'\" mode: nroff
'\" fill-column: 78