Hello community,

here is the log from the commit of package perl-Parse-RecDescent for 
openSUSE:Factory checked in at 2012-06-01 22:31:45
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-Parse-RecDescent (Old)
 and      /work/SRC/openSUSE:Factory/.perl-Parse-RecDescent.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-Parse-RecDescent", Maintainer is "[email protected]"

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/perl-Parse-RecDescent/perl-Parse-RecDescent.changes  
    2012-02-16 16:22:24.000000000 +0100
+++ 
/work/SRC/openSUSE:Factory/.perl-Parse-RecDescent.new/perl-Parse-RecDescent.changes
 2012-06-01 22:32:33.000000000 +0200
@@ -1,0 +2,31 @@
+Thu May 31 13:23:43 UTC 2012 - [email protected]
+
+- updated to 1.967009
+     - Revised ExtUtils::MakeMaker build/configure version
+       requirements. (RT.cpan.org #74787, Thanks Paul!)
+
+     - Revised Text::Balanced prereq to require version 1.95,
+       necessary for t/skip.t to pass.
+       (RT.cpan.org #74787, Thanks Paul!)
+
+     - Removed unused version.pm prereq.
+
+     - Fix a circular reference memory leak caused by the use of
+       $AUTOLOAD in sub AUTOLOAD{} in the generated parser's
+       namespace.  Workaround documented in perl5 RT #110248.
+       Workaround a circular reference memory leak in ISA documented
+       by perl5 RT #92708.  A parser's DESTROY() method redefines all
+       subs before deleting the stash, to avoid circular references
+       between subrules. (RT #53710, thanks Andreas!)
+
+     - Parse::RecDescent::AUTOLOAD did not correctly handle
+       initializing the line counting mechanism when a reference to a
+       scalar was passed to the parser. (RT.cpan.org #27705, thanks
+       Justin!)
+
+     - Restore old _parserepeat calling convention.  Change a
+       parser's DESTROY method to check for $self->{_not_precompiled}
+       instead of $self->{_precompiled}. (Fix for RT #74593).
+
+
+-------------------------------------------------------------------

Old:
----
  Parse-RecDescent-1.965001.patch
  Parse-RecDescent-1.967006.tar.gz

New:
----
  Parse-RecDescent-1.967009.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ perl-Parse-RecDescent.spec ++++++
--- /var/tmp/diff_new_pack.aZH90t/_old  2012-06-01 22:32:34.000000000 +0200
+++ /var/tmp/diff_new_pack.aZH90t/_new  2012-06-01 22:32:34.000000000 +0200
@@ -16,42 +16,36 @@
 #
 
 
-
 Name:           perl-Parse-RecDescent
-Version:        1.967006
+Version:        1.967009
 Release:        0
-License:        GPL-1.0+ or Artistic-1.0
 %define cpan_name Parse-RecDescent
 Summary:        Generate Recursive-Descent Parsers
-Url:            http://search.cpan.org/dist/Parse-RecDescent/
+License:        GPL-1.0+ or Artistic-1.0
 Group:          Development/Libraries/Perl
-#Source:         
http://www.cpan.org/modules/by-module/Parse/Parse-RecDescent-%{version}.tar.gz
-Source:         %{cpan_name}-%{version}.tar.gz
-# bnc#653512
-Patch0:         Parse-RecDescent-1.965001.patch
+Url:            http://search.cpan.org/dist/Parse-RecDescent/
+Source:         
http://www.cpan.org/authors/id/J/JT/JTBRAUN/%{cpan_name}-%{version}.tar.gz
+BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 BuildRequires:  perl
-BuildRequires:  perl(Module::Build)
-BuildRequires:  perl(Test::More)
-BuildRequires:  perl(Test::Warn)
-BuildRequires:  perl(Text::Balanced)
-BuildRequires:  perl(version)
 BuildRequires:  perl-macros
-Requires:       perl(Text::Balanced)
-Requires:       perl(version)
-BuildRoot:      %{_tmppath}/%{name}-%{version}-build
-BuildArch:      noarch
+BuildRequires:  perl(ExtUtils::MakeMaker) >= 6.57
+BuildRequires:  perl(Module::Build)
+#BuildRequires: perl(AutoDump)
+#BuildRequires: perl(Calc)
+#BuildRequires: perl(CGrammar)
+#BuildRequires: perl(DecommentGrammar)
+#BuildRequires: perl(Parse::RecDescent)
 %{perl_requires}
 
 %description
-RecDescent incrementally generates top-down recursive-descent text
-parsers from simple yacc-like grammar specifications.
+Generate Recursive-Descent Parsers
 
 %prep
 %setup -q -n %{cpan_name}-%{version}
-%patch0 -p1
+find . -type f -print0 | xargs -0 chmod 644
 
 %build
-perl Build.PL installdirs=vendor optimize="%{optflags}"
+%{__perl} Build.PL installdirs=vendor optimize="%{optflags}"
 ./Build build flags=%{?_smp_mflags}
 
 %check
@@ -61,11 +55,8 @@
 ./Build install destdir=%{buildroot} create_packlist=0
 %perl_gen_filelist
 
-%clean
-rm -rf %{buildroot}
-
 %files -f %{name}.files
-%defattr(-,root,root,-)
-%doc Changes README
+%defattr(-,root,root,755)
+%doc Changes README ToDo
 
 %changelog

++++++ Parse-RecDescent-1.967006.tar.gz -> Parse-RecDescent-1.967009.tar.gz 
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Parse-RecDescent-1.967006/Build.PL 
new/Parse-RecDescent-1.967009/Build.PL
--- old/Parse-RecDescent-1.967006/Build.PL      2012-02-09 04:10:52.000000000 
+0100
+++ new/Parse-RecDescent-1.967009/Build.PL      2012-02-19 20:55:07.000000000 
+0100
@@ -11,9 +11,8 @@
     ],
     dist_version_from   => 'lib/Parse/RecDescent.pm',
     requires => {
-        'Text::Balanced' => 0,
+        'Text::Balanced' => 1.95,
         'Test::More'     => 0,
-        'version'        => 0,
     },
     add_to_cleanup      => [ 'Parse-RecDescent-*' ],
 );
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Parse-RecDescent-1.967006/Changes 
new/Parse-RecDescent-1.967009/Changes
--- old/Parse-RecDescent-1.967006/Changes       2012-02-11 05:49:25.000000000 
+0100
+++ new/Parse-RecDescent-1.967009/Changes       2012-03-16 15:25:51.000000000 
+0100
@@ -619,8 +619,10 @@
     - Applied fix to restore skipped prefixes on match failure
       (thanks Jeremy!)
 
-    - Removed formats to eliminate problems with filehandle duplication
-      in forked environments
+    - *** NON-BACKWARDS COMPATIBLE CHANGE! *** Removed formats to
+      eliminate problems with filehandle duplication in forked
+      environments.  Removed redirect_reporting_to() in favor of using
+      STDERR for all error/trace output.
 
 1.966_002  Sun Jan 22 19:08:37 2012
 
@@ -760,3 +762,36 @@
 
       - Bumped version to 1.967006 for non-development release.
 
+1.967_007      Thu Feb 23 07:26:03 2012
+
+      - Revised ExtUtils::MakeMaker build/configure version
+        requirements. (RT.cpan.org #74787, Thanks Paul!)
+
+      - Revised Text::Balanced prereq to require version 1.95,
+        necessary for t/skip.t to pass.
+        (RT.cpan.org #74787, Thanks Paul!)
+
+      - Removed unused version.pm prereq.
+
+      - Fix a circular reference memory leak caused by the use of
+        $AUTOLOAD in sub AUTOLOAD{} in the generated parser's
+        namespace.  Workaround documented in perl5 RT #110248.
+        Workaround a circular reference memory leak in ISA documented
+        by perl5 RT #92708.  A parser's DESTROY() method redefines all
+        subs before deleting the stash, to avoid circular references
+        between subrules. (RT #53710, thanks Andreas!)
+
+      - Parse::RecDescent::AUTOLOAD did not correctly handle
+        initializing the line counting mechanism when a reference to a
+        scalar was passed to the parser. (RT.cpan.org #27705, thanks
+        Justin!)
+
+1.967_008      Tue Mar 13 22:28:00 2012
+
+      - Restore old _parserepeat calling convention.  Change a
+        parser's DESTROY method to check for $self->{_not_precompiled}
+        instead of $self->{_precompiled}. (Fix for RT #74593).
+
+1.967009      Fri Mar 16 07:25:09 2012
+
+      - Bumped version to 1.967009 for non-development release.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Parse-RecDescent-1.967006/META.json 
new/Parse-RecDescent-1.967009/META.json
--- old/Parse-RecDescent-1.967006/META.json     2012-02-11 05:51:16.000000000 
+0100
+++ new/Parse-RecDescent-1.967009/META.json     2012-03-16 15:27:02.000000000 
+0100
@@ -23,22 +23,21 @@
    "prereqs" : {
       "build" : {
          "requires" : {
-            "ExtUtils::MakeMaker" : "6.62"
+            "ExtUtils::MakeMaker" : "6.5702"
          }
       },
       "configure" : {
          "requires" : {
-            "ExtUtils::MakeMaker" : "6.62"
+            "ExtUtils::MakeMaker" : "6.5702"
          }
       },
       "runtime" : {
          "requires" : {
             "Test::More" : 0,
-            "Text::Balanced" : 0,
-            "version" : 0
+            "Text::Balanced" : "1.95"
          }
       }
    },
    "release_status" : "stable",
-   "version" : "1.967006"
+   "version" : "1.967009"
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Parse-RecDescent-1.967006/META.yml 
new/Parse-RecDescent-1.967009/META.yml
--- old/Parse-RecDescent-1.967006/META.yml      2012-02-11 05:51:16.000000000 
+0100
+++ new/Parse-RecDescent-1.967009/META.yml      2012-03-16 15:27:02.000000000 
+0100
@@ -4,9 +4,9 @@
   - 'Damian Conway <[email protected]>'
   - 'Jeremy T. Braun <[email protected]>'
 build_requires:
-  ExtUtils::MakeMaker: 6.62
+  ExtUtils::MakeMaker: 6.5702
 configure_requires:
-  ExtUtils::MakeMaker: 6.62
+  ExtUtils::MakeMaker: 6.5702
 dynamic_config: 1
 generated_by: 'ExtUtils::MakeMaker version 6.62, CPAN::Meta::Converter version 
2.113640'
 license: unknown
@@ -20,6 +20,5 @@
     - inc
 requires:
   Test::More: 0
-  Text::Balanced: 0
-  version: 0
-version: 1.967006
+  Text::Balanced: 1.95
+version: 1.967009
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Parse-RecDescent-1.967006/Makefile.PL 
new/Parse-RecDescent-1.967009/Makefile.PL
--- old/Parse-RecDescent-1.967006/Makefile.PL   2012-02-09 04:10:52.000000000 
+0100
+++ new/Parse-RecDescent-1.967009/Makefile.PL   2012-02-19 21:26:03.000000000 
+0100
@@ -12,15 +12,14 @@
     ABSTRACT_FROM    => 'lib/Parse/RecDescent.pm',
     PL_FILES         => {},
     BUILD_REQUIRES   => {
-        'ExtUtils::MakeMaker' => 6.62,
+        'ExtUtils::MakeMaker' => 6.5702,
     },
     CONFIGURE_REQUIRES   => {
-        'ExtUtils::MakeMaker' => 6.62,
+        'ExtUtils::MakeMaker' => 6.5702,
     },
     PREREQ_PM        => {
-        'Text::Balanced' => 0,
+        'Text::Balanced' => 1.95,
         'Test::More'     => 0,
-        'version'        => 0,
     },
     dist             => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', },
     clean            => { FILES => 'Parse-RecDescent-* RD_TRACE' },
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Parse-RecDescent-1.967006/README 
new/Parse-RecDescent-1.967009/README
--- old/Parse-RecDescent-1.967006/README        2012-02-11 05:49:37.000000000 
+0100
+++ new/Parse-RecDescent-1.967009/README        2012-03-16 15:26:10.000000000 
+0100
@@ -1,4 +1,4 @@
-Parse::RecDescent version 1.967006
+Parse::RecDescent version 1.967009
 
 NAME
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Parse-RecDescent-1.967006/lib/Parse/RecDescent.pm 
new/Parse-RecDescent-1.967009/lib/Parse/RecDescent.pm
--- old/Parse-RecDescent-1.967006/lib/Parse/RecDescent.pm       2012-02-11 
05:49:54.000000000 +0100
+++ new/Parse-RecDescent-1.967009/lib/Parse/RecDescent.pm       2012-03-16 
15:26:26.000000000 +0100
@@ -119,7 +119,8 @@
       || croak("Can't compile bad grammar")
       if $grammar;
 
-    $self->{_precompiled} = 1;
+    # Do not allow &DESTROY to remove the precompiled namespace
+    delete $self->{_not_precompiled};
 
     foreach ( keys %{$self->{rules}} ) {
         $self->{rules}{$_}{changed} = 1;
@@ -423,7 +424,7 @@
 
     my $code =
 '
-# ARGS ARE: ($parser, $text; $repeating, $_noactions, $_itempos, \@args)
+# ARGS ARE: ($parser, $text; $repeating, $_noactions, \@args, $_itempos)
 sub ' . $namespace . '::' . $self->{"name"} .  '
 {
        my $thisparser = $_[0];
@@ -454,8 +455,8 @@
     my %item = ();
     my $repeating =  $_[2];
     my $_noactions = $_[3];
-    my $_itempos = $_[4];
-    my @arg =    defined $_[5] ? @{ &{$_[5]} } : ();
+    my @arg =    defined $_[4] ? @{ &{$_[4]} } : ();
+    my $_itempos = $_[5];
     my %arg =    ($#arg & 01) ? @arg : (@arg, undef);
     my $text;
     my $lastsep;
@@ -1489,9 +1490,9 @@
         . $self->callsyntax($namespace.'::')
         . '($thisparser,$text,$repeating,'
         . ($self->{"lookahead"}?'1':'$_noactions')
-        . ($check->{"itempos"}?',$itempos[$#itempos]':',undef')
         . ($self->{argcode} ? ",sub { return $self->{argcode} }"
                    : ',sub { \\@arg }')
+        . ($check->{"itempos"}?',$itempos[$#itempos]':',undef')
         . ')))
         {
             '.($self->{"lookahead"} ? '$text = $_savetext;' : '').'
@@ -1605,10 +1606,10 @@
         . $self->callsyntax($namespace.'::')
         . ', ' . $min . ', ' . $max . ', '
         . ($self->{"lookahead"}?'1':'$_noactions')
-        . ($check->{"itempos"}?',$itempos[$#itempos]':',undef')
         . ',$expectation,'
         . ($self->{argcode} ? "sub { return $self->{argcode} }"
                         : 'sub { \\@arg }')
+        . ($check->{"itempos"}?',$itempos[$#itempos]':',undef')
         . ')))
         {
             
Parse::RecDescent::_trace(q{<<'.Parse::RecDescent::_matchtracemessage($self,1).'
 repeated subrule: ['
@@ -1895,7 +1896,7 @@
 
 my $ERRORS = 0;
 
-our $VERSION = '1.967006';
+our $VERSION = '1.967009';
 $VERSION = eval $VERSION;
 $_FILENAME=__FILE__;
 
@@ -1924,6 +1925,13 @@
         "localvars" => '',
         "_AUTOACTION" => undef,
         "_AUTOTREE"   => undef,
+
+        # Precompiled parsers used to set _precompiled, but that
+        # wasn't present in some versions of Parse::RecDescent used to
+        # build precompiled parsers.  Instead, set a new
+        # _not_precompiled flag, which is remove from future
+        # Precompiled parsers at build time.
+        "_not_precompiled" => 1,
     };
 
 
@@ -1949,7 +1957,35 @@
     my ($self) = @_;
     my $namespace = $self->{namespace};
     $namespace =~ s/Parse::RecDescent:://;
-    if (!$self->{_precompiled}) {
+    if ($self->{_not_precompiled}) {
+        # BEGIN WORKAROUND
+        # Perl has a bug that creates a circular reference between
+        # @ISA and that variable's stash:
+        #   https://rt.perl.org/rt3/Ticket/Display.html?id=92708
+        # Emptying the array before deleting the stash seems to
+        # prevent the leak.  Once the ticket above has been resolved,
+        # these two lines can be removed.
+        no strict 'refs';
+        @{$self->{namespace} . '::ISA'} = ();
+        # END WORKAROUND
+
+        # Some grammars may contain circular references between rules,
+        # such as:
+        #   a: 'ID' | b
+        #   b: '(' a ')'
+        # Unless these references are broken, the subs stay around on
+        # stash deletion below.  Iterate through the stash entries and
+        # for each defined code reference, set it to reference sub {}
+        # instead.
+        {
+            local $^W; # avoid 'sub redefined' warnings.
+            my $blank_sub = sub {};
+            while (my ($name, $glob) = each 
%{"Parse::RecDescent::$namespace\::"}) {
+                *$glob = $blank_sub if defined &$glob;
+            }
+        }
+
+        # Delete the namespace's stash
         delete $Parse::RecDescent::{$namespace.'::'};
     }
 }
@@ -3015,7 +3051,7 @@
     my $self = shift;
     my $initial_skip = defined($self->{skip}) ? $self->{skip} : $skip;
 
-    my $code = qq{
+    my $code = qq!
 package $self->{namespace};
 use strict;
 use vars qw(\$skip \$AUTOLOAD $self->{localvars} );
@@ -3029,12 +3065,19 @@
 *$self->{namespace}::AUTOLOAD   = sub
 {
     no strict 'refs';
-    \$AUTOLOAD =~ s/^$self->{namespace}/Parse::RecDescent/;
-    goto &{\$AUTOLOAD};
+!
+# This generated code uses ${"AUTOLOAD"} rather than $AUTOLOAD in
+# order to avoid the circular reference documented here:
+#    https://rt.perl.org/rt3/Public/Bug/Display.html?id=110248
+# As a result of the investigation of
+#    https://rt.cpan.org/Ticket/Display.html?id=53710
+. qq!
+    \${"AUTOLOAD"} =~ s/^$self->{namespace}/Parse::RecDescent/;
+    goto &{\${"AUTOLOAD"}};
 }
 }
 
-};
+!;
     $code .= "push \@$self->{namespace}\::ISA, 'Parse::RecDescent';";
     $self->{"startcode"} = '';
 
@@ -3059,8 +3102,7 @@
     croak "Could not find method: $AUTOLOAD\n" unless ref $_[0];
     my $class = ref($_[0]) || $_[0];
     my $text = ref($_[1]) eq 'SCALAR' ? ${$_[1]} : "$_[1]";
-    $_[0]->{lastlinenum} = $_[2]||_linecount($_[1]);
-    $_[0]->{lastlinenum} = _linecount($_[1]);
+    $_[0]->{lastlinenum} = _linecount($text);
     $_[0]->{lastlinenum} += ($_[2]||0) if @_ > 2;
     $_[0]->{offsetlinenum} = $_[0]->{lastlinenum};
     $_[0]->{fulltext} = $text;
@@ -3080,7 +3122,15 @@
 
     croak "Unknown starting rule ($AUTOLOAD) called\n"
         unless defined &$AUTOLOAD;
-    my $retval = &{$AUTOLOAD}($_[0],$text,undef,undef,undef,$args);
+    my $retval = &{$AUTOLOAD}(
+        $_[0], # $parser
+        $text, # $text
+        undef, # $repeating
+        undef, # $_noactions
+        $args, # \@args
+        undef, # $_itempos
+    );
+
 
     if (defined $retval)
     {
@@ -3099,7 +3149,7 @@
 
 sub _parserepeat($$$$$$$$$)    # RETURNS A REF TO AN ARRAY OF MATCHES
 {
-    my ($parser, $text, $prod, $min, $max, $_noactions, $_itempos, 
$expectation, $argcode) = @_;
+    my ($parser, $text, $prod, $min, $max, $_noactions, $expectation, 
$argcode, $_itempos) = @_;
     my @tokens = ();
 
     my $itemposfirst;
@@ -3110,7 +3160,7 @@
         my $_savetext = $text;
         my $prevtextlen = length $text;
         my $_tok;
-        if (! defined ($_tok = 
&$prod($parser,$text,1,$_noactions,$_itempos,$argcode)))
+        if (! defined ($_tok = 
&$prod($parser,$text,1,$_noactions,$argcode,$_itempos)))
         {
             $text = $_savetext;
             last;
@@ -3377,8 +3427,8 @@
 
 =head1 VERSION
 
-This document describes version 1.967006 of Parse::RecDescent
-released January 29th, 2012.
+This document describes version 1.967009 of Parse::RecDescent
+released March 16th, 2012.
 
 =head1 SYNOPSIS
 

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to