if ($^O eq 'MacOS') {
$macfiles = eval { require Mac::MoreFiles };
warn 'Mac::MoreFiles could not be loaded; using non-native syscopy'
- if $^W;
+ if $@ && $^W;
}
sub _catname {
=head1 SYNOPSIS
- use File::Copy;
+ use File::Copy;
- copy("file1","file2");
- copy("Copy.pm",\*STDOUT);'
+ copy("file1","file2") or die "Copy failed: $!";
+ copy("Copy.pm",\*STDOUT);
move("/dev1/fileA","/dev2/fileB");
- use POSIX;
+ use POSIX;
use File::Copy cp;
$n = FileHandle->new("/a/file","r");