> On Tue, 8 Aug 2000 06:44:00 +1000 (EST), Damian Conway wrote:
   > 
   > >   > A true value indicates that the file is indeed valid Perl.
   > >
   > >So is an empty file! :-)
   > 
   > That is precisely the problem. You won't get a syntax error if this
   > happens.
   > 
   > Now, bringing in the million monkeys typing, again: the chances of
   > getting a corrupt file that yet is valid Perl source file, is *far*
   > greater, if empty files are allowed as well.
   > 
   > Empty files won't return a true value.
   > 
   > Say you accidently erase the contents of some module file. The
   > requirement of it returning a true value will immediately warn you where
   > things went wrong.

So require and do issue a warning if they require or do an empty file.
Better that than meaningless 1;'s at the end of every module.

Damian

Reply via email to