in reply to Re^3: multiple "sub" packages in 1 file: possible? how?
in thread multiple "sub" packages in 1 file: possible? how?

Exporter::import( 'my_temp_convert' );

Careful! import() is a method, so that line tries to import code from a package named my_temp_convert.

Replies are listed 'Best First'.
Re^5: multiple "sub" packages in 1 file: possible? how?
by naikonta (Curate) on Aug 05, 2007 at 07:09 UTC
    That's the intention, importing symbols from my_temp_convert into main, and I believe that kyle is aware of it. It's the same with my_temp_convert->import call. Both calls are using my_temp_convert as the first argument to the subroutine/method.

    Open source softwares? Share and enjoy. Make profit from them if you can. Yet, share and enjoy!

      Calling methods as functions has the nasty tendency to break your code (and especially my code). In this case when the correct code is both shorter and clearer!