in reply to Re^2: Wrong idioms (open $fh, '<', undef)
in thread Wrong idioms
This will also "open" file without error, if it's not a file, but a directory.
Also, does this have any sense?
In case we don't want an array, it will be converted to 'scalar' anyway.return wantarray ? read_glob_content($fh) : scalar read_glob_content($fh);
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: Wrong idioms (open $fh, '<', undef)
by Anonymous Monk on Mar 30, 2013 at 02:40 UTC | |
by vsespb (Chaplain) on Mar 30, 2013 at 09:04 UTC | |
by Anonymous Monk on Apr 02, 2013 at 08:38 UTC | |
by vsespb (Chaplain) on Apr 02, 2013 at 09:47 UTC | |
by Anonymous Monk on Apr 02, 2013 at 12:12 UTC |
In Section
Seekers of Perl Wisdom