June 2001 Making a Module Back Slide 12 Forward

1

package Sample::Module;
use strict;

BEGIN{
  use Exporter ();
  use vars qw ($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
  $VERSION     = 0.01;
  @ISA         = qw (Exporter);
  @EXPORT      = qw ();
  @EXPORT_OK   = qw ();
  %EXPORT_TAGS = ();
}

#Everything else goes here

1;
__END__

  • All modules (and required files) need to return a true value. The simplest way to guarantee a true value is to end the module with a "1;", which is true.


Copyright © 2001 R. Geoffrey Avery Back Contents Forward