package Records_tagged; $Records_tagged::link_file = '/path/to/some/file'; # fully qualified scalar our $link_file; # lexical scoped global use vars qw($link_file); # package scoped global #### package Records_tagged; use strict; sub new { my $class = shift; my $self = shift; # this only makes sense with Records_tagged->new(\%hash) $self->{link_file} = undef; #### sub new { my $class = shift; my $self = {}; # create an anonymous hash $self->{link_file} = undef;