r41692 - in /branches/upstream/libdevel-declare-perl/current: Changes Declare.xs META.yml lib/Devel/Declare.pm lib/Devel/Declare/Context/Simple.pm lib/Devel/Declare/MethodInstaller/Simple.pm

ryan52-guest at users.alioth.debian.org ryan52-guest at users.alioth.debian.org
Tue Aug 11 23:41:03 UTC 2009


Author: ryan52-guest
Date: Tue Aug 11 23:40:57 2009
New Revision: 41692

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=41692
Log:
[svn-upgrade] Integrating new upstream version, libdevel-declare-perl (0.005010)

Modified:
    branches/upstream/libdevel-declare-perl/current/Changes
    branches/upstream/libdevel-declare-perl/current/Declare.xs
    branches/upstream/libdevel-declare-perl/current/META.yml
    branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare.pm
    branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/Context/Simple.pm
    branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/MethodInstaller/Simple.pm

Modified: branches/upstream/libdevel-declare-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libdevel-declare-perl/current/Changes?rev=41692&op=diff
==============================================================================
--- branches/upstream/libdevel-declare-perl/current/Changes (original)
+++ branches/upstream/libdevel-declare-perl/current/Changes Tue Aug 11 23:40:57 2009
@@ -1,5 +1,18 @@
 Changes for Devel-Declare
 
+0.005010 - 11 Aug 2009
+  - Don't invoke the linestr callback if we found a keyword and the bufptr
+    still contains an arrow at its beginning. This causes the linestr callback
+    not to be fired on things like "->method" (if method is a declarator).
+    While this might be useful, it mostly caused problems so far. It might be
+    added again later as a separate feature.
+
+0.005009 - 10 Aug 2009
+  - Stop mixing declarations with code. (Closes: RT#48548) (Cosimo Streppone)
+  - Move strip_attrs, which is a purely parsing method, from
+    MethodInstaller::Simple to Context::Simple (nperez).
+
+0.005008 - 27 Jul 2009
   - Depend on the latest ExtUtils::Depends for win32+gcc support.
   - Conditionally expand linestrings under perl debugger.
 

Modified: branches/upstream/libdevel-declare-perl/current/Declare.xs
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libdevel-declare-perl/current/Declare.xs?rev=41692&op=diff
==============================================================================
--- branches/upstream/libdevel-declare-perl/current/Declare.xs (original)
+++ branches/upstream/libdevel-declare-perl/current/Declare.xs Tue Aug 11 23:40:57 2009
@@ -381,6 +381,10 @@
       break;
   }
 
+  if (strnEQ (PL_bufptr, "->", 2)) {
+    return o;
+  }
+
   dd_linestr_callback(aTHX_ "const", name);
 
   return o;
@@ -488,6 +492,7 @@
     in_declare = value;
 
 BOOT:
+{
   char *endptr;
   char *debug_str = getenv ("DD_DEBUG");
   if (debug_str) {
@@ -496,3 +501,4 @@
       dd_debug = 0;
     }
   }
+}

Modified: branches/upstream/libdevel-declare-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libdevel-declare-perl/current/META.yml?rev=41692&op=diff
==============================================================================
--- branches/upstream/libdevel-declare-perl/current/META.yml (original)
+++ branches/upstream/libdevel-declare-perl/current/META.yml Tue Aug 11 23:40:57 2009
@@ -29,4 +29,4 @@
 resources:
   license: http://dev.perl.org/licenses/
   repository: git://github.com/rafl/devel-declare.git
-version: 0.005008
+version: 0.005010

Modified: branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare.pm?rev=41692&op=diff
==============================================================================
--- branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare.pm (original)
+++ branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare.pm Tue Aug 11 23:40:57 2009
@@ -4,7 +4,7 @@
 use warnings;
 use 5.008001;
 
-our $VERSION = '0.005008';
+our $VERSION = '0.005010';
 
 use constant DECLARE_NAME => 1;
 use constant DECLARE_PROTO => 2;

Modified: branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/Context/Simple.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/Context/Simple.pm?rev=41692&op=diff
==============================================================================
--- branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/Context/Simple.pm (original)
+++ branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/Context/Simple.pm Tue Aug 11 23:40:57 2009
@@ -189,6 +189,52 @@
   return \@args;
 }
 
+sub strip_attrs {
+  my $self = shift;
+  $self->skipspace;
+
+  my $linestr = Devel::Declare::get_linestr;
+  my $attrs   = '';
+
+  if (substr($linestr, $self->offset, 1) eq ':') {
+    while (substr($linestr, $self->offset, 1) ne '{') {
+      if (substr($linestr, $self->offset, 1) eq ':') {
+        substr($linestr, $self->offset, 1) = '';
+        Devel::Declare::set_linestr($linestr);
+
+        $attrs .= ':';
+      }
+
+      $self->skipspace;
+      $linestr = Devel::Declare::get_linestr();
+
+      if (my $len = Devel::Declare::toke_scan_word($self->offset, 0)) {
+        my $name = substr($linestr, $self->offset, $len);
+        substr($linestr, $self->offset, $len) = '';
+        Devel::Declare::set_linestr($linestr);
+
+        $attrs .= " ${name}";
+
+        if (substr($linestr, $self->offset, 1) eq '(') {
+          my $length = Devel::Declare::toke_scan_str($self->offset);
+          my $arg    = Devel::Declare::get_lex_stuff();
+          Devel::Declare::clear_lex_stuff();
+          $linestr = Devel::Declare::get_linestr();
+          substr($linestr, $self->offset, $length) = '';
+          Devel::Declare::set_linestr($linestr);
+
+          $attrs .= "(${arg})";
+        }
+      }
+    }
+
+    $linestr = Devel::Declare::get_linestr();
+  }
+
+  return $attrs;
+}
+
+
 sub get_curstash_name {
   return Devel::Declare::get_curstash_name;
 }

Modified: branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/MethodInstaller/Simple.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/MethodInstaller/Simple.pm?rev=41692&op=diff
==============================================================================
--- branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/MethodInstaller/Simple.pm (original)
+++ branches/upstream/libdevel-declare-perl/current/lib/Devel/Declare/MethodInstaller/Simple.pm Tue Aug 11 23:40:57 2009
@@ -22,51 +22,6 @@
     $args{into},
     { $args{name} => { const => sub { $ctx->parser(@_) } } }
   );
-}
-
-sub strip_attrs {
-  my $self = shift;
-  $self->skipspace;
-
-  my $linestr = Devel::Declare::get_linestr;
-  my $attrs   = '';
-
-  if (substr($linestr, $self->offset, 1) eq ':') {
-    while (substr($linestr, $self->offset, 1) ne '{') {
-      if (substr($linestr, $self->offset, 1) eq ':') {
-        substr($linestr, $self->offset, 1) = '';
-        Devel::Declare::set_linestr($linestr);
-
-        $attrs .= ':';
-      }
-
-      $self->skipspace;
-      $linestr = Devel::Declare::get_linestr();
-
-      if (my $len = Devel::Declare::toke_scan_word($self->offset, 0)) {
-        my $name = substr($linestr, $self->offset, $len);
-        substr($linestr, $self->offset, $len) = '';
-        Devel::Declare::set_linestr($linestr);
-
-        $attrs .= " ${name}";
-
-        if (substr($linestr, $self->offset, 1) eq '(') {
-          my $length = Devel::Declare::toke_scan_str($self->offset);
-          my $arg    = Devel::Declare::get_lex_stuff();
-          Devel::Declare::clear_lex_stuff();
-          $linestr = Devel::Declare::get_linestr();
-          substr($linestr, $self->offset, $length) = '';
-          Devel::Declare::set_linestr($linestr);
-
-          $attrs .= "(${arg})";
-        }
-      }
-    }
-
-    $linestr = Devel::Declare::get_linestr();
-  }
-
-  return $attrs;
 }
 
 sub code_for {




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