In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/035b6821e6e17ee4ea286a7a8332b86222a67695?hp=0865059d9cec0d198515152182d4283ab634748e>

- Log -----------------------------------------------------------------
commit 035b6821e6e17ee4ea286a7a8332b86222a67695
Author: Father Chrysostomos <[email protected]>
Date:   Sat Jan 28 23:06:25 2012 -0800

    feature.h: Mask hints in CURRENT_FEATURE_BUNDLE
    
    Otherwise CURRENT_FEATURE_BUNDLE will end up including any hints added
    later that happen to use higher bits.
    
    This was causing autobox to turn off all features, causing failures
    for Dist::Zilla::PluginBundle::AVAR.
    
    I’m not adding tests for this, as such tests would need constant
    tweaking in future perl developement.  What autobox is doing is
    naughty and unsupported anyway.
-----------------------------------------------------------------------

Summary of changes:
 feature.h        |    3 ++-
 regen/feature.pl |    3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/feature.h b/feature.h
index 2d06450..60bf41d 100644
--- a/feature.h
+++ b/feature.h
@@ -17,7 +17,8 @@
 
 #define CURRENT_HINTS \
     (PL_curcop == &PL_compiling ? PL_hints : PL_curcop->cop_hints)
-#define CURRENT_FEATURE_BUNDLE (CURRENT_HINTS >> HINT_FEATURE_SHIFT)
+#define CURRENT_FEATURE_BUNDLE \
+    ((CURRENT_HINTS & HINT_FEATURE_MASK) >> HINT_FEATURE_SHIFT)
 
 #define FEATURE_IS_ENABLED(name)                                       \
        ((CURRENT_HINTS                                                  \
diff --git a/regen/feature.pl b/regen/feature.pl
index 05643d9..2444ad1 100755
--- a/regen/feature.pl
+++ b/regen/feature.pl
@@ -226,7 +226,8 @@ print $h <<'EOH';
 
 #define CURRENT_HINTS \
     (PL_curcop == &PL_compiling ? PL_hints : PL_curcop->cop_hints)
-#define CURRENT_FEATURE_BUNDLE (CURRENT_HINTS >> HINT_FEATURE_SHIFT)
+#define CURRENT_FEATURE_BUNDLE \
+    ((CURRENT_HINTS & HINT_FEATURE_MASK) >> HINT_FEATURE_SHIFT)
 
 #define FEATURE_IS_ENABLED(name)                                       \
        ((CURRENT_HINTS                                                  \

--
Perl5 Master Repository

Reply via email to