in reply to Re: importing from variable packages
in thread importing from variable packages

Excellent. Thanks. So how come that works, and the indirect object style doesn't? My tiny brain hurts.

dave hj~

  • Comment on Re: Re: importing from variable packages

Replies are listed 'Best First'.
(tye)Re: importing from variable packages
by tye (Sage) on Mar 15, 2001 at 03:53 UTC

    From my quick testing, these two yield the same results:

    import $pack 'hi'; $pack->import( 'hi' );
    with each of them only producing the error you quoted when $pack is a reference and is not blessed. I don't have a ton of versions of Perl handy and these results were with Perl 5.6.0. Using Perl 5.004_01, I got results too weird to mention.

    So I suspect this is a Perl 5.005 bug you are experiencing.

            - tye (but my friends call me "Tye")