Version 2 of stdout

Updated 2003-09-22 16:03:41

a part of stdio, this file is opened by default for each application making use of the stdio package of code.

This output file may correspond to a disk file, pipe, terminal device, or other construct.

To refer to this output filehandle in Tcl, use the string stdout when using puts .


Tcl 8.3 had a problem on stdout, when it was redirected to a file. The problem was that every buffer write caused a flush of the disk cache. The workaround in 8.3 was to do (once, at beginning of script):

    fconfigure stdout -buffering full -buffersize 262144

so that there were few disk writes performed. (Thanks KBK and the Tcl chatroom for the quick answer! RS)