Hi,
I am a new to Perl and need help with how to return from a function directly after a warn.
This looks like it works but I am not sure if it is okay to do it this way.
rename($name1, $name2) or warn "Can't rename file $name1: $!, error" and return 0;
Thanks
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.