r7367 - in /branches/upstream/libdatetime-format-builder-perl/current: Build.PL Changes MANIFEST META.yml SIGNATURE lib/DateTime/Format/Builder.pm lib/DateTime/Format/Builder/Parser.pm t/memory-cycle.t

dmn at users.alioth.debian.org dmn at users.alioth.debian.org
Tue Sep 11 08:58:12 UTC 2007


Author: dmn
Date: Tue Sep 11 08:58:12 2007
New Revision: 7367

URL: http://svn.debian.org/wsvn/?sc=1&rev=7367
Log:
[svn-upgrade] Integrating new upstream version, libdatetime-format-builder-perl (0.7901)

Added:
    branches/upstream/libdatetime-format-builder-perl/current/t/memory-cycle.t
Modified:
    branches/upstream/libdatetime-format-builder-perl/current/Build.PL
    branches/upstream/libdatetime-format-builder-perl/current/Changes
    branches/upstream/libdatetime-format-builder-perl/current/MANIFEST
    branches/upstream/libdatetime-format-builder-perl/current/META.yml
    branches/upstream/libdatetime-format-builder-perl/current/SIGNATURE
    branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder.pm
    branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder/Parser.pm

Modified: branches/upstream/libdatetime-format-builder-perl/current/Build.PL
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/Build.PL?rev=7367&op=diff
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/Build.PL (original)
+++ branches/upstream/libdatetime-format-builder-perl/current/Build.PL Tue Sep 11 08:58:12 2007
@@ -6,10 +6,11 @@
     ( module_name => 'DateTime::Format::Builder',
       author      => 'Dave Rolsky <autarch at urth.org>',
       license     => 'perl',
-      requires    => { 'DateTime'                   => 0.12,
+      requires    => { 'Class::Factory::Util'       => 1.6,
+                       'DateTime'                   => 0.12,
                        'DateTime::Format::Strptime' => 1.04,
                        'Params::Validate'           => 0.72,
-                       'Class::Factory::Util'       => 1.6,
+                       'Task::Weaken'               => 0,
                      },
       build_requires => { 'Module::Build' => 0 },
       sign        => 1,

Modified: branches/upstream/libdatetime-format-builder-perl/current/Changes
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/Changes?rev=7367&op=diff
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/Changes (original)
+++ branches/upstream/libdatetime-format-builder-perl/current/Changes Tue Sep 11 08:58:12 2007
@@ -1,191 +1,229 @@
-# Change log for DateTime::Format::Builder
-
-
-version: 0.7807
-date:    05 29 2006
-changes:
-    - Fix a test failure in on_fail_regex.t on Win32 (bug in the test code).  Reported by Ben Thul.
-
-version: 0.7806
-date:    09 09 2004
-changes:
-    - When DateTime::Format::Builder::Parser loaded worker classes, it ignored modules located under relative paths.  This was fixed by using Class::Factory::Util for this functionality instead.
-
----
-version: 0.7805
-date:    11 08 2004
-changes:
-    - DateTime::Format::Build::Parser caused an exception when run in taint mode.  Reported by Curtis Hawthorne.
-
----
-version: 0.7805
-date:    11 08 2004
-changes:
-    - DateTime::Format::Build::Parser caused an exception when run in taint mode.  Reported by Curtis Hawthorne.
-
----
-version: 0.7804
-date:    07 Jul 2004
-changes:
-    - No code or doc changes, just change the code in examples to ensure that PAUSE does not index it.
-
----
-version: 0.7803
-date:    13 Feb 2004
-changes:
-    - Localize $_ before calling File::Find, otherwise it will be written over for caller.  Patch from Leon Brocard.
-
----
-version: 0.7802
-date:    13 Feb 2004
-changes:
-    - Add dependency on DateTime::Format::Strptime.
-
----
-version: 0.7801
-date:    26 Jan 2004
-changes:
-    - New maintainer - Dave Rolsky
-    - Switched to a different build/install sysstem (Module::Build instead of Module::Install)
-
----
-version: 0.78
-date:    1 Dec 2003
-changes:
-    - Fix multigroup bug in Dispatch
-    - Add Tivoli example.
-
----
-version: 0.77
-date:    14 Aug 2003
-changes:
-    - Correct package name for Quick.
-    - Augment license conditions.
-    - Fixed timezones in fall.t and quick.t tests.
-
----
-version: 0.76
-date:    10 Aug 2003
-changes:
-    - Fallthrough example and test added.
-    - Quick parser added to simplify fallthrough stuff.
-    - Rejigged internals to allow for on_fail argument to multi-parsers.
-
----
-version: 0.75
-date:    29 Jun 2003
-changes:
-    - Silly MANIFEST.SKIP entry caused dispatch stuff to be skipped.
-
----
-version: 0.74
-date:    28 Jun 2003
-changes:
-    - >
-      Dispatch Parser class added, which allows us to make
-      groups of parsers and hop quickly to them.
-    - >
-      length parameter can now be an arrayref, hence we can
-      have a parser belong to more than one length group.
-    - Version numbers are all identical now.
-    - Regex Parser can call custom constructors.
-    - Wrapped method only regards undef as a failure.
-
----
-version: 0.73
-date:    24 Jun 2003
-changes:
-    - Exit parser more quickly if able.
-    - Multiple same length parsers accepted.
-    - Fixed some perl 5.005 testing problems.
-
----
-version: 0.72
-date:    28 May 2003
-changes:
-    - Minor tweaks for the 'private' tag in META.yml
-
----
-version: 0.71
-date:    23 May 2003
-changes:
-    - Massive doc (re)writing.
-    - Examples tidied up.
-    - Tutorial refactored.
-    - Users of generic.pm get to subclass now rather than coderef.
-
----
-version: 0.69
-date:    28 Apr 2003
-changes:
-    - DateTime::Format::Strptime is now supported.
-    - To support the previous item, massive refactoring.
-    - Minor API changes that shouldn't affect anyone.
-
----
-version: 0.64
-date:    27 Apr 2003
-changes:
-    - Callbacks are given 'args' and 'self' keys.
-    - Callbacks can be arrays of callbacks.
-
----
-version: 0.62
-date:    20 Apr 2003
-changes:
-    - Fixed erroneous call to on_fail()
-    - Added 'verbose' debugging capability.
-    - Added 'constructor' option to create_class/import.
-    - Avoid overwriting developers' own new() functions.
-    - Complain if asked to overwrite methods.
-
----
-version: 0.60
-date:    12 Apr 2003
-changes:
-    - Fixed missing '\' from a few '\d' in the docs.
-    - Added ICal.pm example.
-    - Added import() feature, to save lots of typing.
-    - Completely revised documentation.
-    - croak is same length is given twice.
-    - Assorted refactoring, retouching.
-
----
-version: 0.25
-date:    29 Mar 2003
-changes:
-    - Minor code cleanups.
-    - Bug fix; 'extra' params were being ignored.
-    - Doc fix; 'extra' params with 0 are not recommended.
-
----
-version: 0.24
-date:    25 Mar 2003
-changes:
-    - First release!
-    - Split POD into separate file.
-    - Preprocess option for method building works.
-    - Postprocess option per parser works.
-    - Specification lists can now have coderefs in there.
-
----
-version: 0.23
-date:    25 Mar 2003
-changes:
-    - Improved ancillary files.
-    - Added basic use case test for new classes.
-    - Assorted API changes.
-    - create_class infers package name.
-    - also creates specified methods rather than assumed ones.
-    - Assorted POD updates. Still not complete.
-    - Rejigged to only have an array of hashrefs. Simpler.
-    - No inference of length/key stuff.
-    - zero is now extra and is thus semantically different.
-    - Preliminary pre/post processing per parser provided.
-
----
-version: 0.22
-date:    21 Mar 2003
-changes:
-    - Initial (pre-actual release) version.
-
+0.7901   2007-09-01
+
+- The memory-cycle.t test will fail if you have PadWalker and the
+  current Devel::Cycle (1.07) installed. I forgot I had patched my
+  local Devel::Cycle to fix this bug.
+
+
+0.79     2007-08-30
+
+- Fix several circular references in
+  DateTime::Format::Builder::Parser. This would be triggered by any
+  standard usage of DT::F::Builder. Reported by Carl Franks. RT
+  #29034.
+
+
+0.7807   2006-05-29
+
+- Fix a test failure in on_fail_regex.t on Win32 (bug in the test code).
+  Reported by Ben Thul.
+
+
+0.7806   2004-09-09
+
+- When DateTime::Format::Builder::Parser loaded worker classes, it
+  ignored modules located under relative paths. This was fixed by using
+  Class::Factory::Util for this functionality instead.
+
+
+0.7805   2004-11-08
+
+- DateTime::Format::Build::Parser caused an exception when run in taint
+  mode. Reported by Curtis Hawthorne.
+
+
+0.7805   2004-11-08
+
+- DateTime::Format::Build::Parser caused an exception when run in taint
+  mode. Reported by Curtis Hawthorne.
+
+
+0.7804   2004-07-07
+
+- No code or doc changes, just change the code in examples to ensure
+  that PAUSE does not index it.
+
+
+0.7803   2004-02-13
+
+- Localize $_ before calling File::Find, otherwise it will be written
+  over for caller. Patch from Leon Brocard.
+
+
+0.7802   2004-02-13
+
+- Add dependency on DateTime::Format::Strptime.
+
+
+0.7801   2004-01-26
+
+- New maintainer - Dave Rolsky
+
+- Switched to a different build/install sysstem (Module::Build instead
+  of Module::Install)
+
+
+0.78     2003-12-01
+
+- Fix multigroup bug in Dispatch
+
+- Add Tivoli example.
+
+
+0.77     2003-08-14
+
+- Correct package name for Quick.
+
+- Augment license conditions.
+
+- Fixed timezones in fall.t and quick.t tests.
+
+
+0.76     2003-08-10
+
+- Fallthrough example and test added.
+
+- Quick parser added to simplify fallthrough stuff.
+
+- Rejigged internals to allow for on_fail argument to multi-parsers.
+
+
+0.75     2003-06-29
+
+- Silly MANIFEST.SKIP entry caused dispatch stuff to be skipped.
+
+
+0.74     2003-06-28
+
+- Dispatch Parser class added, which allows us to make groups of parsers
+  and hop quickly to them.
+
+- length parameter can now be an arrayref, hence we can have a parser
+  belong to more than one length group.
+
+- Version numbers are all identical now.
+
+- Regex Parser can call custom constructors.
+
+- Wrapped method only regards undef as a failure.
+
+
+0.73     2003-06-24
+
+- Exit parser more quickly if able.
+
+- Multiple same length parsers accepted.
+
+- Fixed some perl 5.005 testing problems.
+
+
+0.72     2003-05-28
+
+- Minor tweaks for the 'private' tag in META.yml
+
+
+0.71     2003-05-23
+
+- Massive doc (re)writing.
+
+- Examples tidied up.
+
+- Tutorial refactored.
+
+- Users of generic.pm get to subclass now rather than coderef.
+
+
+0.69     2003-04-28
+
+- DateTime::Format::Strptime is now supported.
+
+- To support the previous item, massive refactoring.
+
+- Minor API changes that shouldn't affect anyone.
+
+
+0.64     2003-04-27
+
+- Callbacks are given 'args' and 'self' keys.
+
+- Callbacks can be arrays of callbacks.
+
+
+0.62     2003-04-20
+
+- Fixed erroneous call to on_fail()
+
+- Added 'verbose' debugging capability.
+
+- Added 'constructor' option to create_class/import.
+
+- Avoid overwriting developers' own new() functions.
+
+- Complain if asked to overwrite methods.
+
+
+0.60     2003-04-12
+
+- Fixed missing '\' from a few '\d' in the docs.
+
+- Added ICal.pm example.
+
+- Added import() feature, to save lots of typing.
+
+- Completely revised documentation.
+
+- croak is same length is given twice.
+
+- Assorted refactoring, retouching.
+
+
+0.25     2003-03-29
+
+- Minor code cleanups.
+
+- Bug fix; 'extra' params were being ignored.
+
+- Doc fix; 'extra' params with 0 are not recommended.
+
+
+0.24     2003-03-25
+
+- First release!
+
+- Split POD into separate file.
+
+- Preprocess option for method building works.
+
+- Postprocess option per parser works.
+
+- Specification lists can now have coderefs in there.
+
+
+0.23     2003-03-25
+
+- Improved ancillary files.
+
+- Added basic use case test for new classes.
+
+- Assorted API changes.
+
+- create_class infers package name.
+
+- also creates specified methods rather than assumed ones.
+
+- Assorted POD updates. Still not complete.
+
+- Rejigged to only have an array of hashrefs. Simpler.
+
+- No inference of length/key stuff.
+
+- zero is now extra and is thus semantically different.
+
+- Preliminary pre/post processing per parser provided.
+
+
+0.22     2003-03-21
+
+- Initial (pre-actual release) version.
+
+

Modified: branches/upstream/libdatetime-format-builder-perl/current/MANIFEST
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/MANIFEST?rev=7367&op=diff
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/MANIFEST (original)
+++ branches/upstream/libdatetime-format-builder-perl/current/MANIFEST Tue Sep 11 08:58:12 2007
@@ -38,6 +38,7 @@
 t/fall.t
 t/import.t
 t/lengths.t
+t/memory-cycle.t
 t/mergecb.t
 t/newclass.t
 t/nocon.t

Modified: branches/upstream/libdatetime-format-builder-perl/current/META.yml
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/META.yml?rev=7367&op=diff
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/META.yml (original)
+++ branches/upstream/libdatetime-format-builder-perl/current/META.yml Tue Sep 11 08:58:12 2007
@@ -1,6 +1,6 @@
 ---
 name: DateTime-Format-Builder
-version: 0.7807
+version: 0.7901
 author:
   - |-
     Originally written by Iain Truskett <spoon at cpan.org>, who died on
@@ -15,12 +15,13 @@
   DateTime: 0.12
   DateTime::Format::Strptime: 1.04
   Params::Validate: 0.72
+  Task::Weaken: 0
 build_requires:
   Module::Build: 0
 provides:
   DateTime::Format::Builder:
     file: lib/DateTime/Format/Builder.pm
-    version: 0.7807
+    version: 0.7901
   DateTime::Format::Builder::Parser:
     file: lib/DateTime/Format/Builder/Parser.pm
     version: 0.77
@@ -39,7 +40,7 @@
   DateTime::Format::Builder::Parser::generic:
     file: lib/DateTime/Format/Builder/Parser/generic.pm
     version: 0.77
-generated_by: Module::Build version 0.2801
+generated_by: Module::Build version 0.2808
 meta-spec:
   url: http://module-build.sourceforge.net/META-spec-v1.2.html
   version: 1.2

Modified: branches/upstream/libdatetime-format-builder-perl/current/SIGNATURE
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/SIGNATURE?rev=7367&op=diff
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/SIGNATURE (original)
+++ branches/upstream/libdatetime-format-builder-perl/current/SIGNATURE Tue Sep 11 08:58:12 2007
@@ -1,5 +1,5 @@
 This file contains message digests of all files listed in MANIFEST,
-signed via the Module::Signature module, version 0.54.
+signed via the Module::Signature module, version 0.55.
 
 To verify the content in this distribution, first make sure you have
 Module::Signature installed, then type:
@@ -16,15 +16,15 @@
 
 SHA1 8d50878004d8d5103e1f44dc3df2899419d3a59d AUTHORS
 SHA1 7a95fc8778fbce1f60d222e0d0d1dbb6c649461f Artistic
-SHA1 ec7b318157905373ababaf78de09a2070704cb79 Build.PL
+SHA1 58303707b051600b6c0820b2d7777f6391ae652e Build.PL
 SHA1 531e6b5c470d4726483fd68833391653eace0a92 COPYING
 SHA1 00b8084495b5b9cdc4bcbb7dd90b912b052453ee CREDITS
-SHA1 df5e2a71a296c3e8e4ad9ffabd1f7450c1b8aa88 Changes
+SHA1 271b8d5133450916bf41c038027741e6fcdd943f Changes
 SHA1 7a273ac56274461c440f658bdab758a94b31ac23 INSTALL
 SHA1 a4f818254f51015b8d7606b73db0ad92f8641463 LICENCE
-SHA1 ed129fa78f1289f0a42ad1e8357def6d4935796c MANIFEST
+SHA1 70635bebe1a8231f6558105c94c8990ea00ededa MANIFEST
 SHA1 d31c065d32a5b2b79340912c172c3069d29f32bc MANIFEST.SKIP
-SHA1 78c2821c7bdc943846f85548fe5adfd847cc5600 META.yml
+SHA1 108b5bb7e850196df8ef1023704e024b24d19f47 META.yml
 SHA1 cd14ada78fb37a0d926edd86eddcdf7f939de582 Makefile.PL
 SHA1 6b2a574958154f535e7ea7d1a7946ebb3a34e93c README
 SHA1 f35ac145f4a1379286bf4cebb9f2b268d55e10a4 examples/Apache.pm
@@ -34,9 +34,9 @@
 SHA1 d882c0f4639ed4721524afbd1ac4a5bedb471d9c examples/Simple.pm
 SHA1 bdadcfd2bdbac90edbda48322fea700204dbeb05 examples/Tivoli.pm
 SHA1 319195d800e24f7db0fcb73765c5ffd8abf020cf examples/W3CDTF.pm
-SHA1 a482c6574692becfedaaadb8f4fbd70750b64f2a lib/DateTime/Format/Builder.pm
+SHA1 30cad078a9272a715d516f397235f406a85dfe72 lib/DateTime/Format/Builder.pm
 SHA1 6b9d88d681693cb8ae7fa40a3750980770f34901 lib/DateTime/Format/Builder.pod
-SHA1 afd8b9f3e6a427a4584042be45194fd014da12ca lib/DateTime/Format/Builder/Parser.pm
+SHA1 fa481193752c51ca72e1d14bcc6d9b0a98b5dfea lib/DateTime/Format/Builder/Parser.pm
 SHA1 d5c9f085e6f4915f7b1147cad0dbe60c9f634d44 lib/DateTime/Format/Builder/Parser/Dispatch.pm
 SHA1 cb0bf72d2c17d66d22f97d9d0468a6164f12c12a lib/DateTime/Format/Builder/Parser/Quick.pm
 SHA1 d58def0d461fe63867b5510d5d73f67fc47850d1 lib/DateTime/Format/Builder/Parser/Regex.pm
@@ -54,6 +54,7 @@
 SHA1 62cc29af5fae11eb3df1a0fbc3932f5238356621 t/fall.t
 SHA1 3762c8dff93c42a864e9be17e545f95a7446f2e8 t/import.t
 SHA1 54fa6e9f4f2390f680b2cdf82b2c28c769b4a0b2 t/lengths.t
+SHA1 430b341a1e1a925c286ef5af0c8fba5c1b3b2a01 t/memory-cycle.t
 SHA1 cb106dcdbf3693444dac4c1c2bd02dd8c97b58f9 t/mergecb.t
 SHA1 6d8ad84c0317984a927a72952da0f10d60388fc0 t/newclass.t
 SHA1 ca26f16c40ebd1f956c214e9f7969c24407f7b9a t/nocon.t
@@ -69,9 +70,9 @@
 SHA1 3d6ba3abe89d1799e3d2739237ab1f29affc4192 t/verbose.t
 SHA1 52f251e04fbd2772bff6c6fa62731804895305fc t/wholeclass.t
 -----BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.2.2 (GNU/Linux)
+Version: GnuPG v1.4.6 (GNU/Linux)
 
-iD8DBQFEezev3Or3ZzQuifMRAjLGAJ0cKBQNEET1gjmi8gylwcgaIWFqygCg8sMZ
-4mwmaRZPwZVWxS+YtH+/DM8=
-=5xY3
+iD8DBQFG2dJS3Or3ZzQuifMRArM/AJ9JCgEioSc/t8tAav5HZn08hznlBACdEkDJ
+RuEpCtzNgEq/qQnPdrMy4H4=
+=Z71l
 -----END PGP SIGNATURE-----

Modified: branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder.pm
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder.pm?rev=7367&op=diff
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder.pm (original)
+++ branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder.pm Tue Sep 11 08:58:12 2007
@@ -1,5 +1,5 @@
 package DateTime::Format::Builder;
-# $Id: Builder.pm 3429 2006-05-29 18:03:05Z autarch $
+# $Id: Builder.pm 3748 2007-09-01 20:56:42Z autarch $
 
 =begin comments
 
@@ -17,7 +17,7 @@
 use vars qw( $VERSION %dispatch_data );
 
 my $parser = 'DateTime::Format::Builder::Parser';
-$VERSION = '0.7807';
+$VERSION = '0.7901';
 
 # Developer oriented methods
 

Modified: branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder/Parser.pm
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder/Parser.pm?rev=7367&op=diff
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder/Parser.pm (original)
+++ branches/upstream/libdatetime-format-builder-perl/current/lib/DateTime/Format/Builder/Parser.pm Tue Sep 11 08:58:12 2007
@@ -5,6 +5,7 @@
 use Params::Validate qw(
     validate SCALAR CODEREF UNDEF ARRAYREF
 );
+use Scalar::Util qw( weaken );
 
 =head1 NAME
 
@@ -59,7 +60,18 @@
 }
 
 sub maker { $_[0]->{maker} }
-sub set_maker { $_[0]->{maker} = $_[1]; $_[0] }
+
+sub set_maker
+{
+    my $self  = shift;
+    my $maker = shift;
+
+    $self->{maker} = $maker;
+    weaken $self->{maker}
+        if ref $self->{maker};
+
+    return $self;
+}
 
 sub fail
 {
@@ -395,6 +407,11 @@
     # Who's our maker?
     $obj->set_maker( $options->{maker} ) if exists $options->{maker};
 
+    # We don't want to save the whole options hash as a closure, since
+    # that can cause a circular reference when $options->{maker} is
+    # set.
+    my $preprocess = $options->{preprocess};
+
     # These are the innards of a multi-parser.
     my $parser = sub {
 	my ($self, $date, @args) = @_;
@@ -408,9 +425,9 @@
 
 	my %p;
 	# Preprocess and potentially fill %p
-	if ($options->{preprocess})
-	{
-	    $date = $options->{preprocess}->(
+	if ($preprocess)
+	{
+	    $date = $preprocess->(
 		input => $date, parsed => \%p, %param
 	    );
 	}

Added: branches/upstream/libdatetime-format-builder-perl/current/t/memory-cycle.t
URL: http://svn.debian.org/wsvn/branches/upstream/libdatetime-format-builder-perl/current/t/memory-cycle.t?rev=7367&op=file
==============================================================================
--- branches/upstream/libdatetime-format-builder-perl/current/t/memory-cycle.t (added)
+++ branches/upstream/libdatetime-format-builder-perl/current/t/memory-cycle.t Tue Sep 11 08:58:12 2007
@@ -1,0 +1,40 @@
+use strict;
+use warnings;
+
+use lib 't/lib';
+
+use DateTime::Format::Builder;
+use Test::More;
+
+unless ( eval "use Test::Memory::Cycle; Devel::Cycle->can('_find_cycle_SCALAR'); " )
+{
+    plan skip_all => 'These tests require Test::Memory::Cycle and a working Devel::Cycle (> 1.07).';
+    exit;
+}
+
+plan tests => 4;
+
+{
+    my $builder = DateTime::Format::Builder->new();
+    my $parser = $builder->parser( { strptime => '%Y-%m-%d' } );
+
+    memory_cycle_ok( $parser,
+                     'Make sure parser object does not have circular refs' );
+
+    memory_cycle_ok( $builder,
+                     'Make sure builder object does not have circular refs after making a single parser' );
+}
+
+{
+    my $builder = DateTime::Format::Builder->new();
+    my $parser = $builder->parser( { strptime => '%Y-%m-%d',
+                                     strptime => '%d-%m-%Y',
+                                   } );
+
+    memory_cycle_ok( $parser,
+                     'Make sure parser object does not have circular refs' );
+
+    memory_cycle_ok( $builder,
+                     'Make sure builder object does not have circular refs after making a multi parser' );
+}
+




More information about the Pkg-perl-cvs-commits mailing list