in reply to Re^4: Why do we need a \n with do FILENAME?
in thread Why do we need a \n with do FILENAME?

Actually the sample does not check on define, but on truth

For the $! case, do says

warn "couldn't do $file: $!"    unless defined $return;

The truth case is checking the success of the contained code, not the OS's ability to locate and execute file. I personally would go code diving before weighing in on the appropriateness of perl's behavior.