in reply to using pl/pm and require HELP !

If you can, I would rewrite the file to be a perl module that inherits from Exporter. That would make the interface a lot simpler.

No matter what, I would do the require in the file that actually is using the subroutine. So, regardless of what you choose to do, put the require in mypack.pm.

------
We are the carpenters and bricklayers of the Information Age.

Don't go borrowing trouble. For programmers, this means Worry only about what you need to implement.

Please remember that I'm crufty and crochety. All opinions are purely mine and all code is untested, unless otherwise specified.

Replies are listed 'Best First'.
Re: Re: using pl/pm and require HELP !
by Anonymous Monk on Jul 16, 2003 at 19:33 UTC
    Thank you so much for your reply - yes I would gladly put the code into another package - unfortunately the sub I need is shared elsewhere - and I haven't the time for refactoring at this stage... legacy code and all that! but I may be trying the main:: which might be of use. thanks, all the best