diff options
-rw-r--r--[-rwxr-xr-x] | perlapi.c | 0 | ||||
-rw-r--r--[-rwxr-xr-x] | perlapi.h | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | t/op/filetest.t | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | t/op/subst_amp.t | 0 | ||||
-rw-r--r-- | utils/h2xs.PL | 18 |
5 files changed, 10 insertions, 8 deletions
diff --git a/perlapi.c b/perlapi.c index 6ea713ce16..6ea713ce16 100755..100644 --- a/perlapi.c +++ b/perlapi.c diff --git a/perlapi.h b/perlapi.h index 0dac61aa75..0dac61aa75 100755..100644 --- a/perlapi.h +++ b/perlapi.h diff --git a/t/op/filetest.t b/t/op/filetest.t index e00d5fb7b0..e00d5fb7b0 100644..100755 --- a/t/op/filetest.t +++ b/t/op/filetest.t diff --git a/t/op/subst_amp.t b/t/op/subst_amp.t index e2e7c0e542..e2e7c0e542 100644..100755 --- a/t/op/subst_amp.t +++ b/t/op/subst_amp.t diff --git a/utils/h2xs.PL b/utils/h2xs.PL index 730a730e26..7d72e8a1a8 100644 --- a/utils/h2xs.PL +++ b/utils/h2xs.PL @@ -630,13 +630,14 @@ warn "Writing $ext$modpname/$modfname.pm\n"; print PM <<"END"; package $module; +require 5.005_62; use strict; END if( $opt_X || $opt_c || $opt_A ){ # we won't have our own AUTOLOAD(), so won't have $AUTOLOAD print PM <<'END'; -use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS); +our @EXPORT_OK; END } else{ @@ -644,7 +645,7 @@ else{ # will want Carp. print PM <<'END'; use Carp; -use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS $AUTOLOAD); +our @EXPORT_OK; END } @@ -669,7 +670,7 @@ unless ($opt_A) { # no autoloader whatsoever. } # Determine @ISA. -my $myISA = '@ISA = qw(Exporter'; # We seem to always want this. +my $myISA = 'our @ISA = qw(Exporter'; # We seem to always want this. $myISA .= ' DynaLoader' unless $opt_X; # no XS $myISA .= ');'; print PM "\n$myISA\n\n"; @@ -684,16 +685,16 @@ print PM<<"END"; # This allows declaration use $module ':all'; # If you do not need this, moving things directly into \@EXPORT or \@EXPORT_OK # will save memory. -%EXPORT_TAGS = ( 'all' => [ qw( +our %EXPORT_TAGS = ( 'all' => [ qw( @exported_names ) ] ); -\@EXPORT_OK = ( \@{ \$EXPORT_TAGS{'all'} } ); - -\@EXPORT = ( +our \@EXPORT_OK = ( \@{ \$EXPORT_TAGS{'all'} } ); +our \@EXPORT = qw( + @const_names ); -\$VERSION = '$TEMPLATE_VERSION'; +our \$VERSION = '$TEMPLATE_VERSION'; END @@ -704,6 +705,7 @@ sub AUTOLOAD { # to the AUTOLOAD in AutoLoader. my \$constname; + our $AUTOLOAD; (\$constname = \$AUTOLOAD) =~ s/.*:://; croak "&$module::constant not defined" if \$constname eq 'constant'; my \$val = constant(\$constname, \@_ ? \$_[0] : 0); |