This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Scalar-List-Utils has been upgraded from version 1.40 to 1.41
authorSteve Hay <steve.m.hay@googlemail.com>
Fri, 12 Sep 2014 08:23:00 +0000 (09:23 +0100)
committerSteve Hay <steve.m.hay@googlemail.com>
Fri, 12 Sep 2014 08:23:00 +0000 (09:23 +0100)
This incorporates ca81d15134, which was naughtily not listed as a
CUSTOMIZED file.

Porting/Maintainers.pl
cpan/Scalar-List-Utils/ListUtil.xs
cpan/Scalar-List-Utils/lib/List/Util.pm
cpan/Scalar-List-Utils/lib/List/Util/XS.pm
cpan/Scalar-List-Utils/lib/Scalar/Util.pm
cpan/Scalar-List-Utils/lib/Sub/Util.pm
cpan/Scalar-List-Utils/t/reduce.t
pod/perldelta.pod

index fed16fd..f22220d 100755 (executable)
@@ -954,7 +954,7 @@ use File::Glob qw(:case);
     },
 
     'Scalar-List-Utils' => {
-        'DISTRIBUTION' => 'PEVANS/Scalar-List-Utils-1.40.tar.gz',
+        'DISTRIBUTION' => 'PEVANS/Scalar-List-Utils-1.41.tar.gz',
         'FILES'    => q[cpan/Scalar-List-Utils],
     },
 
index a21e848..515677f 100644 (file)
@@ -321,7 +321,7 @@ CODE:
     SAVESPTR(GvSV(agv));
     SAVESPTR(GvSV(bgv));
     GvSV(agv) = ret;
-    SvSetSV(ret, args[1]);
+    SvSetMagicSV(ret, args[1]);
 #ifdef dMULTICALL
     if(!CvISXSUB(cv)) {
         dMULTICALL;
@@ -331,7 +331,7 @@ CODE:
         for(index = 2 ; index < items ; index++) {
             GvSV(bgv) = args[index];
             MULTICALL;
-            SvSetSV(ret, *PL_stack_sp);
+            SvSetMagicSV(ret, *PL_stack_sp);
         }
 #  ifdef PERL_HAS_BAD_MULTICALL_REFCOUNT
         if(CvDEPTH(multicall_cv) > 1)
@@ -349,7 +349,7 @@ CODE:
             PUSHMARK(SP);
             call_sv((SV*)cv, G_SCALAR);
 
-            SvSetSV(ret, *PL_stack_sp);
+            SvSetMagicSV(ret, *PL_stack_sp);
         }
     }
 
@@ -1196,16 +1196,17 @@ PPCODE:
     if (PL_DBsub && CvGV(cv)) {
         HV *hv = GvHV(PL_DBsub);
 
-        charnew_pkg = HvNAME(stash);
+        char *new_pkg = HvNAME(stash);
 
-        charold_name = GvNAME( CvGV(cv) );
-        charold_pkg = HvNAME( GvSTASH(CvGV(cv)) );
+        char *old_name = GvNAME( CvGV(cv) );
+        char *old_pkg = HvNAME( GvSTASH(CvGV(cv)) );
 
         int old_len = strlen(old_name) + strlen(old_pkg);
         int new_len = strlen(name) + strlen(new_pkg);
 
-        SV** old_data;
-        char* full_name;
+        SV **old_data;
+        char *full_name;
+
         Newxz(full_name, (old_len > new_len ? old_len : new_len) + 3, char);
 
         strcat(full_name, old_pkg);
index 9296221..837b6c8 100644 (file)
@@ -14,7 +14,7 @@ our @EXPORT_OK  = qw(
   all any first min max minstr maxstr none notall product reduce sum sum0 shuffle
   pairmap pairgrep pairfirst pairs pairkeys pairvalues
 );
-our $VERSION    = "1.40";
+our $VERSION    = "1.41";
 our $XS_VERSION = $VERSION;
 $VERSION    = eval $VERSION;
 
index ad45203..f2e01ae 100644 (file)
@@ -2,7 +2,7 @@ package List::Util::XS;
 use strict;
 use List::Util;
 
-our $VERSION = "1.40";       # FIXUP
+our $VERSION = "1.41";       # FIXUP
 $VERSION = eval $VERSION;    # FIXUP
 
 1;
index 043852a..3f17d13 100644 (file)
@@ -17,7 +17,7 @@ our @EXPORT_OK = qw(
   dualvar isdual isvstring looks_like_number openhandle readonly set_prototype
   tainted
 );
-our $VERSION    = "1.40";
+our $VERSION    = "1.41";
 $VERSION   = eval $VERSION;
 
 our @EXPORT_FAIL;
index 6d03163..e40cf22 100644 (file)
@@ -16,7 +16,7 @@ our @EXPORT_OK = qw(
   subname set_subname
 );
 
-our $VERSION    = "1.40";
+our $VERSION    = "1.41";
 $VERSION   = eval $VERSION;
 
 =head1 NAME
@@ -25,7 +25,7 @@ Sub::Util - A selection of utility subroutines for subs and CODE references
 
 =head1 SYNOPSIS
 
-    use Sub::Util qw( set_prototype subname set_subname );
+    use Sub::Util qw( prototype set_prototype subname set_subname );
 
 =head1 DESCRIPTION
 
@@ -47,6 +47,8 @@ that its popularity warrants inclusion in a core module, which this is.
 
     my $proto = prototype( $code )
 
+I<Since version 1.40.>
+
 Returns the prototype of the given C<$code> reference, if it has one, as a
 string. This is the same as the C<CORE::prototype> operator; it is included
 here simply for symmetry and completeness with the other functions.
index b8acbe7..848c34f 100644 (file)
@@ -5,7 +5,7 @@ use warnings;
 
 use List::Util qw(reduce min);
 use Test::More;
-plan tests => 29 + ($::PERL_ONLY ? 0 : 2);
+plan tests => 30 + ($::PERL_ONLY ? 0 : 2);
 
 my $v = reduce {};
 
@@ -160,3 +160,6 @@ ok($@ =~ /^Not a subroutine reference/, 'check for code reference');
 eval { &reduce(+{},1,2,3) };
 ok($@ =~ /^Not a subroutine reference/, 'check for code reference');
 
+my @names = ("a\x{100}c", "d\x{101}efgh", 'ijk');
+my $longest = reduce { length($a) > length($b) ? $a : $b } @names;
+is( length($longest),  6,      'missing SMG rt#121992');
index a8df590..4f02710 100644 (file)
@@ -168,6 +168,10 @@ L<Pod::Perldoc> has been upgraded from version 3.23 to 3.24.
 
 =item *
 
+Scalar-List-Utils has been upgraded from version 1.40 to 1.41.
+
+=item *
+
 L<constant> has been upgraded from version 1.31 to 1.32.
 
 It now accepts fully-qualified constant names, allowing constants to be