r28450 - in /branches/upstream/libhook-lexwrap-perl/current: Changes MANIFEST META.yml is_prerequisite lib/Hook/LexWrap.pm
gregoa at users.alioth.debian.org
gregoa at users.alioth.debian.org
Sun Dec 21 21:56:21 UTC 2008
Author: gregoa
Date: Sun Dec 21 21:56:18 2008
New Revision: 28450
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=28450
Log:
[svn-upgrade] Integrating new upstream version, libhook-lexwrap-perl (0.22)
Added:
branches/upstream/libhook-lexwrap-perl/current/is_prerequisite
Modified:
branches/upstream/libhook-lexwrap-perl/current/Changes
branches/upstream/libhook-lexwrap-perl/current/MANIFEST
branches/upstream/libhook-lexwrap-perl/current/META.yml
branches/upstream/libhook-lexwrap-perl/current/lib/Hook/LexWrap.pm
Modified: branches/upstream/libhook-lexwrap-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libhook-lexwrap-perl/current/Changes?rev=28450&op=diff
==============================================================================
--- branches/upstream/libhook-lexwrap-perl/current/Changes (original)
+++ branches/upstream/libhook-lexwrap-perl/current/Changes Sun Dec 21 21:56:18 2008
@@ -30,6 +30,7 @@
- Fixed C<caller> (thanks everyone)
+
0.21 Nov 6 2008
- Added 'See also: Sub::Prepend'
@@ -41,3 +42,12 @@
- Moved tests to t/. Silenced warnings.
- Added pod.t
+
+
+0.22 Dec 18 2008
+
+ - use strict; use warnings;
+
+ - Added prototype for caller
+
+ - silenced warnings about sub replacements
Modified: branches/upstream/libhook-lexwrap-perl/current/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libhook-lexwrap-perl/current/MANIFEST?rev=28450&op=diff
==============================================================================
--- branches/upstream/libhook-lexwrap-perl/current/MANIFEST (original)
+++ branches/upstream/libhook-lexwrap-perl/current/MANIFEST Sun Dec 21 21:56:18 2008
@@ -7,4 +7,5 @@
t/pod.t
demo/demo_memo.pl
demo/demo_temp.pl
+is_prerequisite
META.yml Module meta-data (added by MakeMaker)
Modified: branches/upstream/libhook-lexwrap-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libhook-lexwrap-perl/current/META.yml?rev=28450&op=diff
==============================================================================
--- branches/upstream/libhook-lexwrap-perl/current/META.yml (original)
+++ branches/upstream/libhook-lexwrap-perl/current/META.yml Sun Dec 21 21:56:18 2008
@@ -1,6 +1,6 @@
--- #YAML:1.0
name: Hook-LexWrap
-version: 0.21
+version: 0.22
abstract: Lexically scoped subroutine wrappers
author:
- Damian Conway (damian at conway.org)
Added: branches/upstream/libhook-lexwrap-perl/current/is_prerequisite
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libhook-lexwrap-perl/current/is_prerequisite?rev=28450&op=file
==============================================================================
--- branches/upstream/libhook-lexwrap-perl/current/is_prerequisite (added)
+++ branches/upstream/libhook-lexwrap-perl/current/is_prerequisite Sun Dec 21 21:56:18 2008
@@ -1,0 +1,8 @@
+primary:
+Class::Accessor::Named Acme::ComeFrom DB::Pluggable Sub::MicroSig Sub::WrapPackages Test::SubCalls Test::TestCoverage Test::UniqueTestNames
+
+part of secondary:
+CGI::Application::Plugin::LogDispatch PPI Template::Provider::Preload
+
+no longer work:
+WWW::Mechanize::Shell OurNet::BBS
Modified: branches/upstream/libhook-lexwrap-perl/current/lib/Hook/LexWrap.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libhook-lexwrap-perl/current/lib/Hook/LexWrap.pm?rev=28450&op=diff
==============================================================================
--- branches/upstream/libhook-lexwrap-perl/current/lib/Hook/LexWrap.pm (original)
+++ branches/upstream/libhook-lexwrap-perl/current/lib/Hook/LexWrap.pm Sun Dec 21 21:56:18 2008
@@ -1,9 +1,13 @@
package Hook::LexWrap;
use 5.006;
-our $VERSION = '0.21';
+use strict;
+use warnings;
+our $VERSION = '0.22';
use Carp;
-*CORE::GLOBAL::caller = sub {
+{
+no warnings 'redefine';
+*CORE::GLOBAL::caller = sub (;$) {
my ($height) = ($_[0]||0);
my $i=1;
my $name_cache;
@@ -15,17 +19,22 @@
return wantarray ? @_ ? @caller : @caller[0..2] : $caller[0];
}
};
-
-sub import { *{caller()."::wrap"} = \&wrap }
-
-sub wrap (*@) {
+}
+
+sub import { no strict 'refs'; *{caller()."::wrap"} = \&wrap }
+
+sub wrap (*@) { ## no critic Prototypes
my ($typeglob, %wrapper) = @_;
$typeglob = (ref $typeglob || $typeglob =~ /::/)
? $typeglob
: caller()."::$typeglob";
- my $original = ref $typeglob eq 'CODE' && $typeglob
+ my $original;
+ {
+ no strict 'refs';
+ $original = ref $typeglob eq 'CODE' && $typeglob
|| *$typeglob{CODE}
|| croak "Can't wrap non-existent subroutine ", $typeglob;
+ }
croak "'$_' value is not a subroutine reference"
foreach grep {$wrapper{$_} && ref $wrapper{$_} ne 'CODE'}
qw(pre post);
@@ -68,7 +77,10 @@
ref $typeglob eq 'CODE' and return defined wantarray
? $imposter
: carp "Uselessly wrapped subroutine reference in void context";
- *{$typeglob} = $imposter;
+ {
+ no strict 'refs';
+ *{$typeglob} = $imposter;
+ }
return unless defined wantarray;
return bless sub{ $unwrap=1 }, 'Hook::LexWrap::Cleanup';
}
More information about the Pkg-perl-cvs-commits
mailing list