The lexical variable $thing, has file scope -- its not visible outside pack.pm -- see Tutorials: Coping with Scoping
For a module to be a module, and to be loadable using use, the package name has to match the filename -- see Tutorials: Simple Module Tutorial
In reply to Re: Writing Modules
by Anonymous Monk
in thread Writing Modules
by perl.j
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |