summaryrefslogtreecommitdiff
path: root/cpan/Memoize
diff options
context:
space:
mode:
authorFlorian Ragwitz <rafl@debian.org>2010-11-29 18:43:06 +0100
committerFlorian Ragwitz <rafl@debian.org>2010-11-29 18:44:50 +0100
commit28502098d789b49672c607a23fd42af03fab5a04 (patch)
tree526dfdcf7edaeab3c5c3a69a95b3881d689b9855 /cpan/Memoize
parentad9e76a8629ed1ac483f0a7ed0e4da40ac5a1a00 (diff)
downloadperl-28502098d789b49672c607a23fd42af03fab5a04.tar.gz
Upgrade Memoize from version 1.01_03 to 1.02
Diffstat (limited to 'cpan/Memoize')
-rw-r--r--cpan/Memoize/Memoize.pm12
-rw-r--r--cpan/Memoize/Memoize/AnyDBM_File.pm2
-rw-r--r--cpan/Memoize/Memoize/Expire.pm7
-rw-r--r--cpan/Memoize/Memoize/ExpireFile.pm2
-rw-r--r--cpan/Memoize/Memoize/ExpireTest.pm2
-rw-r--r--cpan/Memoize/Memoize/NDBM_File.pm2
-rw-r--r--cpan/Memoize/Memoize/SDBM_File.pm2
-rw-r--r--cpan/Memoize/Memoize/Storable.pm2
-rw-r--r--cpan/Memoize/README82
9 files changed, 17 insertions, 96 deletions
diff --git a/cpan/Memoize/Memoize.pm b/cpan/Memoize/Memoize.pm
index 0cecbcab0a..1ebc174139 100644
--- a/cpan/Memoize/Memoize.pm
+++ b/cpan/Memoize/Memoize.pm
@@ -7,11 +7,9 @@
# You may copy and distribute this program under the
# same terms as Perl itself. If in doubt,
# write to mjd-perl-memoize+@plover.com for a license.
-#
-# Version 1.01 $Revision: 1.18 $ $Date: 2001/06/24 17:16:47 $
package Memoize;
-$VERSION = '1.01_03';
+$VERSION = '1.02';
# Compile-time constants
sub SCALAR () { 0 }
@@ -266,9 +264,9 @@ sub _memoizer {
# Otherwise, we cached an array containing the returned list:
return @$val;
} else {
- my @q = &{$info->{U}}(@_);
- $cache->{$argstr} = $info->{O}{LIST_CACHE} eq 'MERGE' ? $q [0] : \@q;
- @q;
+ my @q = &{$info->{U}}(@_);
+ $cache->{$argstr} = $info->{O}{LIST_CACHE} eq 'MERGE' ? $q [0] : \@q;
+ @q;
}
} else {
croak "Internal error \#42; context was neither LIST nor SCALAR\n";
@@ -362,7 +360,7 @@ Memoize - Make functions faster by trading space for time
=head1 SYNOPSIS
- # This is the documentation for Memoize 1.01
+ # This is the documentation for Memoize 1.02
use Memoize;
memoize('slow_function');
slow_function(arguments); # Is faster than it was before
diff --git a/cpan/Memoize/Memoize/AnyDBM_File.pm b/cpan/Memoize/Memoize/AnyDBM_File.pm
index 91f960962f..078f69e011 100644
--- a/cpan/Memoize/Memoize/AnyDBM_File.pm
+++ b/cpan/Memoize/Memoize/AnyDBM_File.pm
@@ -11,7 +11,7 @@ See L<Memoize>.
=cut
use vars qw(@ISA $VERSION);
-$VERSION = 0.65;
+$VERSION = '1.02';
@ISA = qw(DB_File GDBM_File Memoize::NDBM_File Memoize::SDBM_File ODBM_File) unless @ISA;
my $verbose = 1;
diff --git a/cpan/Memoize/Memoize/Expire.pm b/cpan/Memoize/Memoize/Expire.pm
index 97e1aa4420..3d6d3e439c 100644
--- a/cpan/Memoize/Memoize/Expire.pm
+++ b/cpan/Memoize/Memoize/Expire.pm
@@ -3,7 +3,7 @@ package Memoize::Expire;
# require 5.00556;
use Carp;
$DEBUG = 0;
-$VERSION = '1.00';
+$VERSION = '1.02';
# This package will implement expiration by prepending a fixed-length header
# to the font of the cached data. The format of the header will be:
@@ -311,6 +311,11 @@ the underlying cache so that the user can specify that the cache is
also persistent or that it has some other interesting semantics. The
example above demonstrates how to do this, as does C<Memoize::Expire>.
+Another sample module, L<Memoize::Saves>, is available in a separate
+distribution on CPAN. It implements a policy that allows you to
+specify that certain function values would always be looked up afresh.
+See the documentation for details.
+
=head1 ALTERNATIVES
Brent Powers has a C<Memoize::ExpireLRU> module that was designed to
diff --git a/cpan/Memoize/Memoize/ExpireFile.pm b/cpan/Memoize/Memoize/ExpireFile.pm
index e52c09a3bf..e3123b8340 100644
--- a/cpan/Memoize/Memoize/ExpireFile.pm
+++ b/cpan/Memoize/Memoize/ExpireFile.pm
@@ -10,7 +10,7 @@ See L<Memoize::Expire>.
=cut
-$VERSION = 1.01;
+$VERSION = '1.02';
use Carp;
my $Zero = pack("N", 0);
diff --git a/cpan/Memoize/Memoize/ExpireTest.pm b/cpan/Memoize/Memoize/ExpireTest.pm
index 729f6b9850..3c69e56c9f 100644
--- a/cpan/Memoize/Memoize/ExpireTest.pm
+++ b/cpan/Memoize/Memoize/ExpireTest.pm
@@ -18,7 +18,7 @@ to mjd-perl-memoize+@plover.com.
=cut
-$VERSION = 0.65;
+$VERSION = '1.02';
my %cache;
sub TIEHASH {
diff --git a/cpan/Memoize/Memoize/NDBM_File.pm b/cpan/Memoize/Memoize/NDBM_File.pm
index 96eabfbb7c..07b8950a60 100644
--- a/cpan/Memoize/Memoize/NDBM_File.pm
+++ b/cpan/Memoize/Memoize/NDBM_File.pm
@@ -12,7 +12,7 @@ See L<Memoize>.
use NDBM_File;
@ISA = qw(NDBM_File);
-$VERSION = 0.65;
+$VERSION = '1.02';
$Verbose = 0;
diff --git a/cpan/Memoize/Memoize/SDBM_File.pm b/cpan/Memoize/Memoize/SDBM_File.pm
index f66273f274..6cb11af732 100644
--- a/cpan/Memoize/Memoize/SDBM_File.pm
+++ b/cpan/Memoize/Memoize/SDBM_File.pm
@@ -12,7 +12,7 @@ See L<Memoize>.
use SDBM_File;
@ISA = qw(SDBM_File);
-$VERSION = 0.65;
+$VERSION = '1.02';
$Verbose = 0;
diff --git a/cpan/Memoize/Memoize/Storable.pm b/cpan/Memoize/Memoize/Storable.pm
index 4c29dd7eb8..33e35b485e 100644
--- a/cpan/Memoize/Memoize/Storable.pm
+++ b/cpan/Memoize/Memoize/Storable.pm
@@ -11,7 +11,7 @@ See L<Memoize>.
=cut
use Storable ();
-$VERSION = 0.65;
+$VERSION = '1.02';
$Verbose = 0;
sub TIEHASH {
diff --git a/cpan/Memoize/README b/cpan/Memoize/README
deleted file mode 100644
index 552f621236..0000000000
--- a/cpan/Memoize/README
+++ /dev/null
@@ -1,82 +0,0 @@
-
-Name: Memoize
-What: Transparently speed up functions by caching return values.
-Version: 1.00
-Author: Mark-Jason Dominus (mjd-perl-memoize+@plover.com)
-
-################################################################
-
-How to build me:
-
- perl Makefile.PL
- make
- make test
-
-There's a very small chance that the tests in speed.t and
-expire_module_t.t might fail because of clock skew or bizarre system
-load conditions. If the tests there fail, rerun them and see if the
-problem persists.
-
-If the tests work,
-
- make install
-
-If not, please send me a report that mentions which tests failed.
-The address is: mjd-perl-memoize+@plover.com.
-
-################################################################
-What's new since 0.66:
-
-Minor documentation and test changes only.
-
-################################################################
-What's new since 0.65:
-
-Test changes only.
-
- 0.62 was the fist version that would be distributed with Perl.
- I got so absorbed in integrating it that I wrote some tests
- that used Time::HiRes. I knew this was safe because
- Time::HiRes is also distributed with the same versions of
- Perl. I totally forgot that some people will get the module
- off of CPAN without Perl and they may not have TIme::HiRes.
- Sorry!
-
-################################################################
-What's new since 0.62:
-
-
- N O T I C E !
-
- ****************************************************************
- ** **
- ** The TIE option is now strongly deprecated. It will be **
- ** permanently removed in the NEXT release of Memoize. **
- ** Please convert all extant software to use HASH instead. **
- ** **
- ** See the manual for details. **
- ** **
- ****************************************************************
-
-I'm sorry about this. I hate making incompatible changes. But as of
-v0.65, Memoize is included in the Perl core. It is about to become
-much more difficult to make incompatible interface changes; if I don't
-get rid of TIE now, I may not get another chance.
-
-TIE presented serious problems. First, it had a bizarre syntax. But
-the big problem was that it was difficult and complicated for
-expiration manager authors to support; evern expiration manager had to
-duplicate the logic for handling TIE. HASH is much simpler to use,
-more powerful, and is trivial for expiration managers to support.
-
-Many long-awaited cleanups and bug fixes.
-
-Memoize now works under threaded perl
-
-Slow tests speeded up. More test file improvements.
-
-Long-standing LIST_CACHE bug cleared up---it turns out that there
-never was a bug. I put in tests for it anyway.
-
-Manual increased.
-