in reply to Open with 'undef' filename.
As a special case the 3-arg form with a read/write mode and the third argument being undef: open(my $tmp, "+>", undef) or die ... opens a filehandle to an anonymous temporary file.
I believe the term "anonymous temporary file" is related to this on *nix. I know nothing more about that.
On Windows it creates a very ordinary file in the users home directory with a name of plx????.tmp where ???? are 4 hex digits. And those files are automatically delete when the process ends.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Open with 'undef' filename.
by james28909 (Deacon) on Nov 07, 2016 at 00:23 UTC |