In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/f25474b0531878b277e2bd50a823ced1a3df6000?hp=3c075feabc1b777553a63a5a7d87ef482f2e3d49>

- Log -----------------------------------------------------------------
commit f25474b0531878b277e2bd50a823ced1a3df6000
Author: Chris 'BinGOs' Williams <ch...@bingosnet.co.uk>
Date:   Mon Feb 3 13:14:02 2014 +0000

    Bump version version and remove/update customisations

M       Porting/Maintainers.pl
M       t/porting/customized.dat

commit d2b110e6a5467455bc4a3d333ec4f1abc5383bd8
Author: John Peacock <john.peac...@havurah-software.org>
Date:   Mon Feb 3 07:48:57 2014 -0500

    Sync bleadperl to version.pm 0.9908
    
    Attached is a patch to bring blead up to date with the latest CPAN
    release of version.pm 0.9908.  All tests pass (except the expected
    porting/customized.t).
    
    I'm hopeful that this will be the last update for a while.  Thanks to
    Daniel Dragan for his insistent prodding to improve the code. ;-)
    
    Thanks
    
    John
    
    >From c501530aa386a3ccbdb35bcccbccd35d70315651 Mon Sep 17 00:00:00 2001
    From: John Peacock <jpeac...@cpan.org>
    Date: Sun, 2 Feb 2014 11:57:44 -0500
    Subject: [PATCH] Update bleadperl to CPAN 0.9908 release
    
    Signed-off-by: Chris 'BinGOs' Williams <ch...@bingosnet.co.uk>

M       cpan/version/lib/version.pm
M       cpan/version/lib/version/regex.pm
M       cpan/version/lib/version/vpp.pm
M       cpan/version/t/00impl-pp.t
M       cpan/version/t/01base.t
M       cpan/version/t/02derived.t
M       cpan/version/t/03require.t
M       cpan/version/t/05sigdie.t
M       cpan/version/t/06noop.t
M       cpan/version/t/07locale.t
M       cpan/version/t/08_corelist.t
M       cpan/version/t/09_list_util.t
M       vutil.c
-----------------------------------------------------------------------

Summary of changes:
 Porting/Maintainers.pl            |   4 +-
 cpan/version/lib/version.pm       |   2 +-
 cpan/version/lib/version/regex.pm |   2 +-
 cpan/version/lib/version/vpp.pm   | 125 +++++++++++++++++++-------------------
 cpan/version/t/00impl-pp.t        |   2 +-
 cpan/version/t/01base.t           |   2 +-
 cpan/version/t/02derived.t        |   2 +-
 cpan/version/t/03require.t        |   2 +-
 cpan/version/t/05sigdie.t         |   2 +-
 cpan/version/t/06noop.t           |   2 +-
 cpan/version/t/07locale.t         |   4 +-
 cpan/version/t/08_corelist.t      |   2 +-
 cpan/version/t/09_list_util.t     |   2 +-
 t/porting/customized.dat          |   5 +-
 vutil.c                           |   5 ++
 15 files changed, 80 insertions(+), 83 deletions(-)

diff --git a/Porting/Maintainers.pl b/Porting/Maintainers.pl
index 40bd9e7..201ec8a 100755
--- a/Porting/Maintainers.pl
+++ b/Porting/Maintainers.pl
@@ -1266,7 +1266,7 @@ use File::Glob qw(:case);
     },
 
     'version' => {
-        'DISTRIBUTION' => 'JPEACOCK/version-0.9907.tar.gz',
+        'DISTRIBUTION' => 'JPEACOCK/version-0.9908.tar.gz',
         'FILES'        => q[cpan/version vutil.c vutil.h vxs.inc],
         'EXCLUDED' => [
             qr{^vutil/lib/},
@@ -1281,8 +1281,6 @@ use File::Glob qw(:case);
         'CUSTOMIZED'   => [
             qw( lib/version.pm
                 ),
-            # Waiting to be merged upstream: see CPAN RT#92536
-            't/07locale.t', 'lib/version/vpp.pm', 'vutil.c'
         ],
 
         'MAP' => {
diff --git a/cpan/version/lib/version.pm b/cpan/version/lib/version.pm
index 280c859..b337a90 100644
--- a/cpan/version/lib/version.pm
+++ b/cpan/version/lib/version.pm
@@ -6,7 +6,7 @@ use strict;
 
 use vars qw(@ISA $VERSION $CLASS $STRICT $LAX *declare *qv);
 
-$VERSION = 0.9907;
+$VERSION = 0.9908;
 $CLASS = 'version';
 
 # avoid using Exporter
diff --git a/cpan/version/lib/version/regex.pm 
b/cpan/version/lib/version/regex.pm
index 1c8f6e1..f92c78b 100644
--- a/cpan/version/lib/version/regex.pm
+++ b/cpan/version/lib/version/regex.pm
@@ -4,7 +4,7 @@ use strict;
 
 use vars qw($VERSION $CLASS $STRICT $LAX);
 
-$VERSION = 0.9907;
+$VERSION = 0.9908;
 
 #--------------------------------------------------------------------------#
 # Version regexp components
diff --git a/cpan/version/lib/version/vpp.pm b/cpan/version/lib/version/vpp.pm
index 3ef1170..3ac3f13 100644
--- a/cpan/version/lib/version/vpp.pm
+++ b/cpan/version/lib/version/vpp.pm
@@ -122,7 +122,7 @@ use strict;
 
 use Config;
 use vars qw($VERSION $CLASS @ISA $LAX $STRICT);
-$VERSION = 0.9907;
+$VERSION = 0.9908;
 $CLASS = 'version::vpp';
 
 require version::regex;
@@ -634,78 +634,78 @@ sub scan_version {
     return $s;
 }
 
-sub new
-{
-       my ($class, $value) = @_;
-       unless (defined $class) {
-           require Carp;
-           Carp::croak('Usage: version::new(class, version)');
-       }
-       my $self = bless ({}, ref ($class) || $class);
-       my $qv = FALSE;
-
-       if ( ref($value) && eval('$value->isa("version")') ) {
-           # Can copy the elements directly
-           $self->{version} = [ @{$value->{version} } ];
-           $self->{qv} = 1 if $value->{qv};
-           $self->{alpha} = 1 if $value->{alpha};
-           $self->{original} = ''.$value->{original};
-           return $self;
-       }
+sub new {
+    my $class = shift;
+    unless (defined $class or $#_ > 1) {
+       require Carp;
+       Carp::croak('Usage: version::new(class, version)');
+    }
 
-       if ( not defined $value or $value =~ /^undef$/ ) {
-           # RT #19517 - special case for undef comparison
-           # or someone forgot to pass a value
-           push @{$self->{version}}, 0;
-           $self->{original} = "0";
-           return ($self);
-       }
+    my $self = bless ({}, ref ($class) || $class);
+    my $qv = FALSE;
 
-       if ( $#_ == 2 ) { # must be CVS-style
-           $value = $_[2];
-           $qv = TRUE;
-       }
+    if ( $#_ == 1 ) { # must be CVS-style
+       $qv = TRUE;
+    }
+    my $value = pop; # always going to be the last element
 
-       if (ref($value) =~ m/ARRAY|HASH/) {
-           require Carp;
-           Carp::croak("Invalid version format (non-numeric data)");
-       }
+    if ( ref($value) && eval('$value->isa("version")') ) {
+       # Can copy the elements directly
+       $self->{version} = [ @{$value->{version} } ];
+       $self->{qv} = 1 if $value->{qv};
+       $self->{alpha} = 1 if $value->{alpha};
+       $self->{original} = ''.$value->{original};
+       return $self;
+    }
+
+    if ( not defined $value or $value =~ /^undef$/ ) {
+       # RT #19517 - special case for undef comparison
+       # or someone forgot to pass a value
+       push @{$self->{version}}, 0;
+       $self->{original} = "0";
+       return ($self);
+    }
 
-       $value = _un_vstring($value);
 
-       if ($Config{d_setlocale}) {
-           use POSIX qw/locale_h/;
-           use if $Config{d_setlocale}, 'locale';
-           my $currlocale = setlocale(LC_ALL);
+    if (ref($value) =~ m/ARRAY|HASH/) {
+       require Carp;
+       Carp::croak("Invalid version format (non-numeric data)");
+    }
 
-           # if the current locale uses commas for decimal points, we
-           # just replace commas with decimal places, rather than changing
-           # locales
-           if ( localeconv()->{decimal_point} eq ',' ) {
-               $value =~ tr/,/./;
-           }
-       }
+    $value = _un_vstring($value);
 
-       # exponential notation
-       if ( $value =~ /\d+.?\d*e[-+]?\d+/ ) {
-           $value = sprintf("%.9f",$value);
-           $value =~ s/(0+)$//; # trim trailing zeros
+    if ($Config{d_setlocale}) {
+       use POSIX qw/locale_h/;
+       use if $Config{d_setlocale}, 'locale';
+       my $currlocale = setlocale(LC_ALL);
+
+       # if the current locale uses commas for decimal points, we
+       # just replace commas with decimal places, rather than changing
+       # locales
+       if ( localeconv()->{decimal_point} eq ',' ) {
+           $value =~ tr/,/./;
        }
+    }
 
-       my $s = scan_version($value, \$self, $qv);
+    # exponential notation
+    if ( $value =~ /\d+.?\d*e[-+]?\d+/ ) {
+       $value = sprintf("%.9f",$value);
+       $value =~ s/(0+)$//; # trim trailing zeros
+    }
 
-       if ($s) { # must be something left over
-           warn("Version string '%s' contains invalid data; "
-                       ."ignoring: '%s'", $value, $s);
-       }
+    my $s = scan_version($value, \$self, $qv);
 
-       return ($self);
+    if ($s) { # must be something left over
+       warn("Version string '%s' contains invalid data; "
+                  ."ignoring: '%s'", $value, $s);
+    }
+
+    return ($self);
 }
 
 *parse = \&new;
 
-sub numify
-{
+sub numify {
     my ($self) = @_;
     unless (_verify($self)) {
        require Carp;
@@ -745,8 +745,7 @@ sub numify
     return $string;
 }
 
-sub normal
-{
+sub normal {
     my ($self) = @_;
     unless (_verify($self)) {
        require Carp;
@@ -781,8 +780,7 @@ sub normal
     return $string;
 }
 
-sub stringify
-{
+sub stringify {
     my ($self) = @_;
     unless (_verify($self)) {
        require Carp;
@@ -795,8 +793,7 @@ sub stringify
            : $self->numify;
 }
 
-sub vcmp
-{
+sub vcmp {
     require UNIVERSAL;
     my ($left,$right,$swap) = @_;
     my $class = ref($left);
diff --git a/cpan/version/t/00impl-pp.t b/cpan/version/t/00impl-pp.t
index 836a75a..ba540c9 100644
--- a/cpan/version/t/00impl-pp.t
+++ b/cpan/version/t/00impl-pp.t
@@ -9,7 +9,7 @@ use Test::More qw/no_plan/;
 BEGIN {
     (my $coretests = $0) =~ s'[^/]+\.t'coretests.pm';
     require $coretests;
-    use_ok('version::vpp', 0.9907);
+    use_ok('version::vpp', 0.9908);
 }
 
 BaseTests("version::vpp","new","qv");
diff --git a/cpan/version/t/01base.t b/cpan/version/t/01base.t
index 3c7edcf..b452e3b 100644
--- a/cpan/version/t/01base.t
+++ b/cpan/version/t/01base.t
@@ -9,7 +9,7 @@ use Test::More qw/no_plan/;
 BEGIN {
     (my $coretests = $0) =~ s'[^/]+\.t'coretests.pm';
     require $coretests;
-    use_ok('version', 0.9907);
+    use_ok('version', 0.9908);
 }
 
 BaseTests("version","new","qv");
diff --git a/cpan/version/t/02derived.t b/cpan/version/t/02derived.t
index 5bd4437..ee9e674 100644
--- a/cpan/version/t/02derived.t
+++ b/cpan/version/t/02derived.t
@@ -10,7 +10,7 @@ use File::Temp qw/tempfile/;
 BEGIN {
     (my $coretests = $0) =~ s'[^/]+\.t'coretests.pm';
     require $coretests;
-    use_ok("version", 0.9907);
+    use_ok("version", 0.9908);
     # If we made it this far, we are ok.
 }
 
diff --git a/cpan/version/t/03require.t b/cpan/version/t/03require.t
index 48ddcd6..c394728 100644
--- a/cpan/version/t/03require.t
+++ b/cpan/version/t/03require.t
@@ -14,7 +14,7 @@ BEGIN {
 # Don't want to use, because we need to make sure that the import doesn't
 # fire just yet (some code does this to avoid importing qv() and delare()).
 require_ok("version");
-is $version::VERSION, 0.9907, "Make sure we have the correct class";
+is $version::VERSION, 0.9908, "Make sure we have the correct class";
 ok(!"main"->can("qv"), "We don't have the imported qv()");
 ok(!"main"->can("declare"), "We don't have the imported declare()");
 
diff --git a/cpan/version/t/05sigdie.t b/cpan/version/t/05sigdie.t
index a145450..8b5b375 100644
--- a/cpan/version/t/05sigdie.t
+++ b/cpan/version/t/05sigdie.t
@@ -14,7 +14,7 @@ BEGIN {
 }
 
 BEGIN {
-    use version 0.9907;
+    use version 0.9908;
 }
 
 pass "Didn't get caught by the wrong DIE handler, which is a good thing";
diff --git a/cpan/version/t/06noop.t b/cpan/version/t/06noop.t
index 97c7e65..66baef4 100644
--- a/cpan/version/t/06noop.t
+++ b/cpan/version/t/06noop.t
@@ -7,7 +7,7 @@
 use Test::More qw/no_plan/;
 
 BEGIN {
-    use_ok('version', 0.9907);
+    use_ok('version', 0.9908);
 }
 
 my $v1 = version->new('1.2');
diff --git a/cpan/version/t/07locale.t b/cpan/version/t/07locale.t
index de6588c..d852aec 100644
--- a/cpan/version/t/07locale.t
+++ b/cpan/version/t/07locale.t
@@ -11,7 +11,7 @@ use Test::More tests => 7;
 use Config;
 
 BEGIN {
-    use_ok('version', 0.9907);
+    use_ok('version', 0.9908);
 }
 
 SKIP: {
@@ -31,7 +31,7 @@ SKIP: {
                                                      # because have to
                                                      # evaluate in current
                                                      # scope
-       use locale;
+       use if $^O !~ /android/, 'locale';
 
        while (<DATA>) {
            chomp;
diff --git a/cpan/version/t/08_corelist.t b/cpan/version/t/08_corelist.t
index 48c61c3..310c9cd 100644
--- a/cpan/version/t/08_corelist.t
+++ b/cpan/version/t/08_corelist.t
@@ -5,7 +5,7 @@
 #########################
 
 use Test::More tests => 3;
-use_ok("version", 0.9907);
+use_ok("version", 0.9908);
 
 # do strict lax tests in a sub to isolate a package to test importing
 SKIP: {
diff --git a/cpan/version/t/09_list_util.t b/cpan/version/t/09_list_util.t
index 110c1a0..d0e3fa9 100644
--- a/cpan/version/t/09_list_util.t
+++ b/cpan/version/t/09_list_util.t
@@ -4,7 +4,7 @@
 #########################
 
 use strict;
-use_ok("version", 0.9907);
+use_ok("version", 0.9908);
 use Test::More;
 
 BEGIN {
diff --git a/t/porting/customized.dat b/t/porting/customized.dat
index a477894..3e699df 100644
--- a/t/porting/customized.dat
+++ b/t/porting/customized.dat
@@ -19,7 +19,4 @@ autodie cpan/autodie/t/utf8_open.t 
5295851351c49f939008c5aca6a798742b1e503d
 libnet cpan/libnet/Makefile.PL 8cc723f0e1d2177af46ef4e41fc1f362085520df
 podlators cpan/podlators/scripts/pod2man.PL 
f81acf53f3ff46cdcc5ebdd661c5d13eb35d20d6
 podlators cpan/podlators/scripts/pod2text.PL 
b4693fcfe4a0a1b38a215cfb8985a65d5d025d69
-version cpan/version/lib/version.pm f7952056c0697efcc986aabf851f999b52a775ab
-version cpan/version/lib/version/vpp.pm 
edd6cfa9f1b4df0894e9455723970f4335b95651
-version cpan/version/t/07locale.t 57aafb192b93ec8cf23b12c632e8126ef49da91a
-version vutil.c 693f2c5719674a55468ca7d680b7d976527817b5
+version cpan/version/lib/version.pm fa9931d4db05aff9a0a6ef558610b1a472d9306e
diff --git a/vutil.c b/vutil.c
index 96aa6f6..4cf0173 100644
--- a/vutil.c
+++ b/vutil.c
@@ -553,7 +553,9 @@ Perl_upg_version(pTHX_ SV *ver, bool qv)
     const MAGIC *mg;
 #endif
 
+#if PERL_VERSION_LT(5,19,8) && defined(USE_ITHREADS)
     ENTER;
+#endif
     PERL_ARGS_ASSERT_UPG_VERSION;
 
     if ( SvNOK(ver) && !( SvPOK(ver) && SvCUR(ver) == 3 ) )
@@ -656,7 +658,10 @@ Perl_upg_version(pTHX_ SV *ver, bool qv)
        Perl_ck_warner(aTHX_ packWARN(WARN_MISC), 
                       "Version string '%s' contains invalid data; "
                       "ignoring: '%s'", version, s);
+
+#if PERL_VERSION_LT(5,19,8) && defined(USE_ITHREADS)
     LEAVE;
+#endif
     return ver;
 }
 

--
Perl5 Master Repository

Reply via email to