in reply to Vexed $Package::Var Usage

Do you end your package with a true value ? (usually a 1; on the last line, uhm before __END__, if you use it).
package Blah; my $a = 3; 1;
Update: check perlboot and perltoot for an introduction on writing package, since yours is VERY basic :)
Greetz
Beatnik
... Quidquid perl dictum sit, altum viditur.

Replies are listed 'Best First'.
Re: Re: Vexed $Package::Var Usage
by chromatic (Archbishop) on Dec 17, 2001 at 04:49 UTC
    Guru meditation: 3 is true.

    Hint: what is the return value of '=' ?

    Update: Bigger hint: what is the return value of my $a = 3;?

      I doubt there is a difference between using 1; and 3;. According to the cookbook (IIRC), anything can be used (anything as in barewords). An equal sign, unquoted would generate an error, quoted would work just fine (altho strict would probably freak).

      Greetz
      Beatnik
      ... Quidquid perl dictum sit, altum viditur.
Re: Re: Vexed $Package::Var Usage
by Anonymous Monk on Dec 17, 2001 at 03:54 UTC
    The true value didn't fix it.

    But thanks for the perldoc refs. I go read them now.