From: Jesse Luehrs Date: Fri, 14 May 2010 16:52:21 +0000 (-0500) Subject: s/Stash::Manip/Package::Stash/g X-Git-Tag: 0.15~1 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=16d8eca580362f17d9baa95fbe99a481d72de319;p=p5sagit%2Fnamespace-clean.git s/Stash::Manip/Package::Stash/g --- diff --git a/Changes b/Changes index a63f632..38410b8 100644 --- a/Changes +++ b/Changes @@ -1,4 +1,4 @@ - - Use Stash::Manip for the stash manipulation bits (doy). + - Use Package::Stash for the stash manipulation bits (doy). [0.14] Thu Mar 18 11:15:38 CET 2010 - Disable auto_install. diff --git a/Makefile.PL b/Makefile.PL index ad21f64..a444a3b 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -13,7 +13,7 @@ build_requires q{Test::More}, '0.88'; build_requires q{FindBin}, 0; requires q{B::Hooks::EndOfScope}, '0.07'; -requires q{Stash::Manip}, '0.01'; +requires q{Package::Stash}, '0.03'; requires q{Sub::Name}, '0.04'; requires q{Sub::Identify}, '0.04'; diff --git a/lib/namespace/clean.pm b/lib/namespace/clean.pm index d31d2a8..4baaebc 100644 --- a/lib/namespace/clean.pm +++ b/lib/namespace/clean.pm @@ -11,7 +11,7 @@ use strict; use vars qw( $VERSION $STORAGE_VAR $SCOPE_HOOK_KEY $SCOPE_EXPLICIT ); use B::Hooks::EndOfScope; -use Stash::Manip; +use Package::Stash; use Sub::Identify qw(sub_fullname); use Sub::Name qw(subname); @@ -161,8 +161,8 @@ my $RemoveSubs = sub { my $cleanee = shift; my $store = shift; - my $cleanee_stash = Stash::Manip->new($cleanee); - my $deleted_stash = Stash::Manip->new("namespace::clean::deleted::$cleanee"); + my $cleanee_stash = Package::Stash->new($cleanee); + my $deleted_stash = Package::Stash->new("namespace::clean::deleted::$cleanee"); SYMBOL: for my $f (@_) { my $variable = "&$f"; @@ -231,7 +231,7 @@ sub import { # calling class, all current functions and our storage my $functions = $pragma->get_functions($cleanee); my $store = $pragma->get_class_store($cleanee); - my $stash = Stash::Manip->new($cleanee); + my $stash = Package::Stash->new($cleanee); # except parameter can be array ref or single value my %except = map {( $_ => 1 )} ( @@ -296,7 +296,7 @@ information about function names included and excluded from removal. sub get_class_store { my ($pragma, $class) = @_; - my $stash = Stash::Manip->new($class); + my $stash = Package::Stash->new($class); return $stash->get_package_symbol("%$STORAGE_VAR"); } @@ -311,7 +311,7 @@ reference to the symbol as value. sub get_functions { my ($pragma, $class) = @_; - my $stash = Stash::Manip->new($class); + my $stash = Package::Stash->new($class); return { map { $_ => $stash->get_package_symbol("&$_") } $stash->list_all_package_symbols('CODE')