unlink question
[email protected] (ToddAndMargo via perl6-users) Thu, 9 Oct 2025 00:35:22 -0700
| Newsgroups | perl.perl6.users |
|---|---|
| Message-ID | <[email protected]> |
Hi All,
Fedora 41
rakudo-pkg-2024.7.0-01.x86_64
I had a problem where this would randomly not
delete the file and not give me the error print
when delete failed:
if not unlink $OldFileName {
PrintRedErr( "Unable to Delete OldFileName <$OldFileName>\n" );
}
But this change fix it right up:
unlink $OldFileName;
if $OldFileName.IO.e {
PrintRedErr( "Unable to Delete OldFileName <$OldFileName>\n" );
}
What in the world did I do wrong on the original?
Yours in confusion,
-T