SPUG: Re: spug-list Digest, Vol 18, Issue 12

bergeron at stu.beloit.edu bergeron at stu.beloit.edu
Wed Dec 29 10:00:31 CST 2004


I would just point out that %ENV is a builtin hash, not an
array, although they're sort of interchangable in perl.

I'm also not sure what Sachin means when he says "> i am
using path /usr/bin/perl for executing a perl .pm file from
within the file".  Sachin, are you trying to include a
perlmod here, or actually execute another perl script?

Nick

You're probably doing something like using ENV() (with
parentheses) instead
of ENV{} (with curly brackets). ENV{} is a builtin array
that holds your
environment variables. ENV() is a function you would have to
define.

On Wed, Dec 29, 2004 at 06:14:05PM +0550, Sachin Chaturvedi
wrote:
> i am working in linux platform with a perl script.
>
> i am using path /usr/bin/perl for executing a perl .pm
file from within the file
.
>
> but i am facing a problem that it gives message like
>
> Can't call method "ENV" without a package or object
reference at ....
>
> when there is a reference to ENV .
>
> Is this problem with perl version as this script has been
written for perl5plus
and i am using /bin/perl OR
>
> i have to include some package for getting this work
>
> Thanks
>
> Sachin


More information about the spug-list mailing list