return 1 if caller;
Then running perl module.pm will execute the program at the end:
--# -x method $ perl -x module.pm Do what? # bare method (not what you want) $ perl module.pm Can't return outside a subroutine at module.pm line 6. # Now with caller() $ perl module.pm Do what?
In reply to Re: RFC: Runnable test code integrated into Modules.
by jmcnamara
in thread RFC: Runnable test code integrated into Modules.
by BrowserUk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |