The change to the internal representation introduced a bug whereby
[p5sagit/p5-mst-13.2.git] / lib / autouse.pm
index d320195..85db01f 100644 (file)
@@ -3,7 +3,7 @@ package autouse;
 #use strict;           # debugging only
 use 5.003_90;          # ->can, for my $var
 
-$autouse::VERSION = '1.02';
+$autouse::VERSION = '1.04';
 
 $autouse::DEBUG ||= 0;
 
@@ -73,9 +73,10 @@ sub import {
 sub vet_import ($) {
     my $module = shift;
     if (my $import = $module->can('import')) {
-       croak "autoused module has unique import() method"
+       croak "autoused module $module has unique import() method"
            unless defined(&Exporter::import)
-                  && $import == \&Exporter::import;
+                  && ($import == \&Exporter::import ||
+                      $import == \&UNIVERSAL::import)
     }
 }
 
@@ -119,7 +120,7 @@ will work and is the equivalent to:
 
    use Module qw(func3);
 
-Its not a very useful feature and has been deprecated.
+It is not a very useful feature and has been deprecated.
 
 =end _deprecated