This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
rename &warnings::register to avoid ambiguity
[perl5.git] / lib / vars.pm
index cff63d6..8ec107c 100644 (file)
@@ -2,18 +2,18 @@ package vars;
 
 use 5.006;
 
-our $VERSION = '1.01';
+our $VERSION = '1.02';
 
 use warnings::register;
 use strict qw(vars subs);
 
 sub import {
     my $callpack = caller;
-    my ($pack, @imports) = @_;
+    my (undef, @imports) = @_;
     my ($sym, $ch);
     foreach (@imports) {
         if (($ch, $sym) = /^([\$\@\%\*\&])(.+)/) {
-           if ($sym =~ /\P{IsWord}/) {
+           if ($sym =~ /\W/) {
                # time for a more-detailed check-up
                if ($sym =~ /^\w+[[{].*[]}]$/) {
                    require Carp;