Avoid "Prototype mismatch" warnings with autouse.
authorRafael Garcia-Suarez <rgarciasuarez@gmail.com>
Wed, 1 Feb 2006 15:51:35 +0000 (15:51 +0000)
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>
Wed, 1 Feb 2006 15:51:35 +0000 (15:51 +0000)
p4raw-id: //depot/perl@27034

lib/autouse.pm

index 67c4e01..30eef50 100644 (file)
@@ -3,7 +3,7 @@ package autouse;
 #use strict;           # debugging only
 use 5.003_90;          # ->can, for my $var
 
-$autouse::VERSION = '1.05';
+$autouse::VERSION = '1.06';
 
 $autouse::DEBUG ||= 0;
 
@@ -53,7 +53,7 @@ sub import {
                require $pm;
                vet_import $module;
            }
-            no warnings 'redefine';
+            no warnings qw(redefine prototype);
            *$closure_import_func = \&{"${module}::$closure_func"};
            print "autousing $module; "
                  ."imported $closure_func as $closure_import_func\n"