In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/2d1c5561244ffb488f4901ad84c08f3fc6443be9?hp=e52529ca2472f8f4697aeab0a74a65c9c5189801>

- Log -----------------------------------------------------------------
commit 2d1c5561244ffb488f4901ad84c08f3fc6443be9
Author: Sébastien Aperghis-Tramoni <[email protected]>
Date:   Tue Sep 4 07:42:26 2012 +0200

    Make dual-lived constant.pm work on 5.8 again
    
    Before releasing the version of constant.pm from bleadperl to the CPAN,
    I tested it with the versions of Perl I have by hand, and it appears
    that the current code fails to compile on 5.8:
    
      Bareword "_DOWNGRADE" not allowed while "strict subs" in use at
      lib/constant.pm line 142.
    
    Added by bd8cb5529605f33aa9cf95d6c471386b3a0e015d
    
    Removing the short-circuit return allows the code to compile and the
    tests to pass on all stable Perl from 5.8.2 to 5.16.1.
-----------------------------------------------------------------------

Summary of changes:
 dist/constant/lib/constant.pm |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/dist/constant/lib/constant.pm b/dist/constant/lib/constant.pm
index ef618c4..f3c2a57 100644
--- a/dist/constant/lib/constant.pm
+++ b/dist/constant/lib/constant.pm
@@ -4,7 +4,7 @@ use strict;
 use warnings::register;
 
 use vars qw($VERSION %declared);
-$VERSION = '1.23';
+$VERSION = '1.24';
 
 #=======================================================================
 
@@ -32,7 +32,6 @@ BEGIN {
 
     # Before this makes its way into a dev perl release, we have to do
     # browser-sniffing, as it were....
-    return unless $const;
     *{chr 256} = \3;
     if (exists ${__PACKAGE__."::"}{"\xc4\x80"}) {
        delete ${__PACKAGE__."::"}{"\xc4\x80"};
@@ -130,7 +129,7 @@ sub import {
            if ($multiple || @_ == 1) {
                my $scalar = $multiple ? $constants->{$name} : $_[0];
 
-               if (_DOWNGRADE) { # for 5.10 to 5.14
+               if (_DOWNGRADE) { # for 5.8 to 5.14
                    # Work around perl bug #31991: Sub names (actually glob
                    # names in general) ignore the UTF8 flag. So we have to
                    # turn it off to get the "right" symbol table entry.

--
Perl5 Master Repository

Reply via email to