in reply to Re^2: Using IO::File to redirect STDOUT
in thread Using IO::File to redirect STDOUT

That's wrong.
"This means that any of the methods in IO::File"
should read
"This means that any of the methods in IO::Handle"

The following are methods IO::File has, but IO::Handle does not:

Replies are listed 'Best First'.
Re^4: Using IO::File to redirect STDOUT
by njcodewarrior (Pilgrim) on May 09, 2006 at 01:31 UTC

    Okay, bear with me as I'm more confused than ever. Here's another piece directly from the text (pp 30 - 31):

    "...$result = $fh->open($filename,[,$mode [,$perms]]) You can reopen a filehandle object on the indicated file by using its open() method. The input arguments are identical to new(). The method result indicates wheter the open was successful.
    This is chiefly used for reopening the standard filehandles STDOUT, STDIN, and STDERR. For example:
    STDOUT->open(">log.txt") or die "Can't reopen STDOUT: $!";
    Calls to print() will now write to the file log.txt...."

    This is also incorrect?

    Thanks again for the help,
    njcodewarrior

      That's the code you had in your OP. As you know, that doesn't work.
Re^4: Using IO::File to redirect STDOUT
by adamk (Chaplain) on May 09, 2006 at 00:04 UTC
    Although of course in the case of seek/tell/sysseek it is because IO::Handle is _also_ not an IO::Seekable object.

    @IO::File::ISA = qw{ IO::Handle IO::Seekable };