package Bar; use SharedVariables qw(:scalars); sub Print { print "Bar Scalar1 $scalar1\n"; } sub Set { $scalar1 = 'Bar'; print "Set Bar\n"; } 1;