r40020 - in /trunk/libparse-method-signatures-perl: Changes MANIFEST META.yml Makefile.PL README debian/changelog debian/control lib/Parse/Method/Signatures.pm t/signatures.t

jawnsy-guest at users.alioth.debian.org jawnsy-guest at users.alioth.debian.org
Thu Jul 16 21:56:04 UTC 2009


Author: jawnsy-guest
Date: Thu Jul 16 21:55:48 2009
New Revision: 40020

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=40020
Log:
* New upstream release
  + Fix use of regular expressions in signatures

Removed:
    trunk/libparse-method-signatures-perl/README
Modified:
    trunk/libparse-method-signatures-perl/Changes
    trunk/libparse-method-signatures-perl/MANIFEST
    trunk/libparse-method-signatures-perl/META.yml
    trunk/libparse-method-signatures-perl/Makefile.PL
    trunk/libparse-method-signatures-perl/debian/changelog
    trunk/libparse-method-signatures-perl/debian/control
    trunk/libparse-method-signatures-perl/lib/Parse/Method/Signatures.pm
    trunk/libparse-method-signatures-perl/t/signatures.t

Modified: trunk/libparse-method-signatures-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/Changes?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/Changes (original)
+++ trunk/libparse-method-signatures-perl/Changes Thu Jul 16 21:55:48 2009
@@ -1,4 +1,8 @@
 Changelog for Parse::Method::Signatures
+
+1.003009 - 2009/07/16
+  - Fix 'Use of uninitialized value' when using regexps in signatures
+  - Depend on MooseX::Traits 0.06 to remove warning about 'bare has' attribute
 
 1.003008 - 2009/06/25
   - Fix ppi.t for the __MOP__ object key (Jesse Luehrs).

Modified: trunk/libparse-method-signatures-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/MANIFEST?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/MANIFEST (original)
+++ trunk/libparse-method-signatures-perl/MANIFEST Thu Jul 16 21:55:48 2009
@@ -23,7 +23,6 @@
 Makefile.PL
 MANIFEST			This list of files
 META.yml
-README
 t/ppi.t
 t/signatures.t
 t/struct.t

Modified: trunk/libparse-method-signatures-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/META.yml?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/META.yml (original)
+++ trunk/libparse-method-signatures-perl/META.yml Thu Jul 16 21:55:48 2009
@@ -25,7 +25,7 @@
 provides:
   Parse::Method::Signatures:
     file: lib/Parse/Method/Signatures.pm
-    version: 1.003008
+    version: 1.003009
   Parse::Method::Signatures::Param:
     file: lib/Parse/Method/Signatures/Param.pm
   Parse::Method::Signatures::Param::Bindable:
@@ -53,7 +53,7 @@
 requires:
   List::MoreUtils: 0
   Moose: 0
-  MooseX::Traits: 0
+  MooseX::Traits: 0.06
   MooseX::Types: 0.10
   MooseX::Types::Moose: 0
   MooseX::Types::Structured: 0
@@ -63,4 +63,4 @@
   homepage: http://github.com/ashb/parse-method-signatures/tree/master
   license: http://dev.perl.org/licenses/
   repository: git://github.com/ashb/parse-method-signatures.git
-version: 1.003008
+version: 1.003009

Modified: trunk/libparse-method-signatures-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/Makefile.PL?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/Makefile.PL (original)
+++ trunk/libparse-method-signatures-perl/Makefile.PL Thu Jul 16 21:55:48 2009
@@ -1,4 +1,4 @@
-use inc::Module::Install 0.79;
+use inc::Module::Install 0.91;
 
 use strict;
 use warnings;
@@ -8,7 +8,7 @@
 
 requires 'List::MoreUtils';
 requires 'Moose';
-requires 'MooseX::Traits';
+requires 'MooseX::Traits' => '0.06';
 requires 'MooseX::Types' => '0.10';
 requires 'MooseX::Types::Moose';
 requires 'MooseX::Types::Structured';
@@ -34,5 +34,5 @@
 );
 
 auto_provides;
-#auto_install;
+auto_install();
 WriteAll;

Modified: trunk/libparse-method-signatures-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/debian/changelog?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/debian/changelog (original)
+++ trunk/libparse-method-signatures-perl/debian/changelog Thu Jul 16 21:55:48 2009
@@ -1,3 +1,10 @@
+libparse-method-signatures-perl (1.003009-1) UNRELEASED; urgency=low
+
+  * New upstream release
+    + Fix use of regular expressions in signatures
+
+ -- Jonathan Yu <frequency at cpan.org>  Thu, 16 Jul 2009 12:47:20 -0400
+
 libparse-method-signatures-perl (1.003008-1) unstable; urgency=low
 
   [ Nathan Handler ]

Modified: trunk/libparse-method-signatures-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/debian/control?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/debian/control (original)
+++ trunk/libparse-method-signatures-perl/debian/control Thu Jul 16 21:55:48 2009
@@ -5,8 +5,8 @@
 Build-Depends-Indep: perl (>= 5.6.0-12), libtest-exception-perl,
  libtest-differences-perl, libmoosex-types-structured-perl,
  libaliased-perl, libppi-perl (>= 1.203), libmoosex-types-perl (>= 0.10),
- libmoosex-traits-perl, libnamespace-clean-perl (>= 0.10), libmoose-perl,
- liblist-moreutils-perl
+ libmoosex-traits-perl (>= 0.06), libnamespace-clean-perl (>= 0.10),
+ libmoose-perl, liblist-moreutils-perl
 Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
 Uploaders: Ryan Niebur <ryanryan52 at gmail.com>
 Standards-Version: 3.8.2
@@ -18,8 +18,8 @@
 Architecture: all
 Depends: ${perl:Depends}, ${misc:Depends}, libppi-perl (>= 1.203),
  libmoosex-types-perl (>= 0.10), libmoosex-types-structured-perl,
- libmoosex-traits-perl, libnamespace-clean-perl (>= 0.10), libmoose-perl,
- liblist-moreutils-perl
+ libmoosex-traits-perl (>= 0.06), libnamespace-clean-perl (>= 0.10),
+ libmoose-perl, liblist-moreutils-perl
 Description: Perl module to parse Perl6-like method signatures
  Parse::Method::Signatures takes a method signature and extracts information
  about it. For users of Perl5 who are unfamiliar with this feature, it is

Modified: trunk/libparse-method-signatures-perl/lib/Parse/Method/Signatures.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/lib/Parse/Method/Signatures.pm?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/lib/Parse/Method/Signatures.pm (original)
+++ trunk/libparse-method-signatures-perl/lib/Parse/Method/Signatures.pm Thu Jul 16 21:55:48 2009
@@ -15,7 +15,7 @@
 use Carp qw/croak/;
 
 use namespace::clean -except => 'meta';
-our $VERSION = '1.003008';
+our $VERSION = '1.003009';
 our $ERROR_LEVEL = 0;
 our %LEXTABLE;
 our $DEBUG = $ENV{PMS_DEBUG} || 0;
@@ -155,11 +155,14 @@
 sub _replace_regexps {
   my ($self, $doc) = @_;
 
+  REGEXP:
   foreach my $node ( @{ $doc->find('Token::Regexp') || [] } ) {
     my $str = $node->content;
 
+    next REGEXP unless defined $node->{operator};
+
     # Rather annoyingly, there are *no* methods on Token::Regexp;
-    my ($word, $rest) = $str =~ /^(@{[$node->{operator}]})(.*)$/s;
+    my ($word, $rest) = $str =~ /^(\Q@{[$node->{operator}]}\E)(.*)$/s;
 
     my $subdoc = PPI::Document->new(\$rest);
     my @to_add = reverse map { $_->remove } $subdoc->children;

Modified: trunk/libparse-method-signatures-perl/t/signatures.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libparse-method-signatures-perl/t/signatures.t?rev=40020&op=diff
==============================================================================
--- trunk/libparse-method-signatures-perl/t/signatures.t (original)
+++ trunk/libparse-method-signatures-perl/t/signatures.t Thu Jul 16 21:55:48 2009
@@ -141,7 +141,15 @@
     ['($x = $a[0])',            'invalid label contents'],
 );
 
-plan tests => scalar @sigs * 3 + scalar @alternative + scalar @invalid;
+my @no_warn = (
+    ['($x where { $_ =~ /foo/ })', 'Regexp without operator' ]
+);
+
+plan tests => scalar @sigs * 3 
+            + scalar @alternative 
+            + scalar @invalid
+            + scalar @no_warn
+;
 
 test_sigs(sub {
     my ($input, $msg, $todo) = @_;
@@ -168,6 +176,8 @@
     dies_ok { Parse::Method::Signatures->signature($sig) } $msg;
 }, @invalid);
 
+test_no_warn(@no_warn);
+
 sub test_sigs {
     my ($test, @sigs) = @_;
 
@@ -179,3 +189,20 @@
         }
     }
 }
+
+sub test_no_warn {
+    my (@sigs) = @_;
+
+    my $warnings = "";
+    local $SIG{__WARN__} = sub { $warnings .= "@_"; };
+
+    for my $row (@sigs) {
+        my ($sig, $msg, $todo) = @{ $row };
+        TODO: {
+            $warnings = "";
+            local $TODO = $todo if $todo;
+            Parse::Method::Signatures->signature($sig);
+            is("", $warnings, $msg || "'$sig' generated no warnings");
+        }
+    }
+}




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