Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
I had just added a library function to my general use library when I suddenly started getting a redefined subroutine warning for File::Basename (see below) from a program that had been running warning free until that moment. Both the main program and the new library function specify use File::Basename.
That should not be a problem if your library declares a package name. Don't make perl4-style libs that just dump all their functions into your main program -- you will regret it. It was always my understanding that use and require would not try to load a module a second time if it was already listed in %INC. They will still call import() a second-time though. In reply to Re: An Interesting Gotcha With use/require
by perrin
|
|