Help for this page

Select Code to Download


  1. or download this
    package A1;
    use A2;
    use C;
    ...
        print "In A1: ".C::TYPE->{VEG}."\n";
        A2::functionA();
    }
    
  2. or download this
    package A2;
    use C;
    sub functionA
    {
        print "In A2: ".C::TYPE->{VEG}."\n";
    }
    
  3. or download this
    package C;
    use A2;
    use constant {
    ...
            MEAT => 3,
        },
    };
    
  4. or download this
    use A2;
    A2::functionA(); # prints "In A2: 2"
    
  5. or download this
    use A1;
    A1::functionA(); # prints "In A1: 2\nIn A2: 2"