I had a look at the source of Slurp and I would love to understand how does slurp()
work:
sub slurp {
local( $/, @ARGV ) = ( wantarray ? $/ : undef, @_ );
return <ARGV>;
}
Where is the file even opened?
See ARGV
and $/
in perldoc perlvar.
See also Path::Class:File::slurp.