Question about the IO::File->open method



The IO::File module has the open method that you use to open a file.
It returns a filehandle.

You can use this IO::File->open to open a file in different modes -

1) by the PERL mode:
$fh = new IO::File ("< filename.txt");

2) by the fopen() mode:
$fh = new IO::File "filename", "r";

3) by the open() mode:
$fh = new IO::File "filename", O_APPEND|O_WRONLY

I'm a Solaris 10, running Perl 5.6.1.

If we go deeper in the IO::FILE module, which function does Perl use
for the system level call? open() or fopen()

Functionally, there's no difference between fopen() and open() but
fopen() is a register function while open() is placed on the stack.

Which one does IO::File use on a Solaris?

Thanx,
Doomster

.



Relevant Pages