make this work with (and require) latest Moose, 0.51
Dave Rolsky [Fri, 27 Jun 2008 03:42:35 +0000 (03:42 +0000)]
Build.PL
Changes
lib/MooseX/StrictConstructor/Meta/Method/Constructor.pm

index 5710f77..e1fd756 100644 (file)
--- a/Build.PL
+++ b/Build.PL
@@ -8,7 +8,7 @@ use Module::Build;
 my $builder = Module::Build->new
     ( module_name        => 'MooseX::StrictConstructor',
       license            => 'perl',
-      requires           => { 'Moose'      => 0.26,
+      requires           => { 'Moose'      => 0.51,
                               'Test::More' => 0,
                             },
       create_makefile_pl => 'passthrough',
diff --git a/Changes b/Changes
index ad89455..61e3792 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,3 +1,8 @@
+0.06   2008-06-27
+
+- Changes to the immutable bits to work with the latest Moose (0.51).
+
+
 0.05   2008-04-18
 
 - The fix in 0.04 only worked for non-immutable classes.
index 9e82ec0..06d5b10 100644 (file)
@@ -25,7 +25,7 @@ override '_generate_BUILDALL' => sub ## no critic RequireArgUnpacking
     $source .= <<"EOF";
 my \%attrs = (@attrs);
 
-my \@bad = sort grep { ! \$attrs{\$_} }  keys \%params;
+my \@bad = sort grep { ! \$attrs{\$_} }  keys \%{ \$params };
 
 if (\@bad) {
     Carp::confess "Found unknown attribute(s) passed to the constructor: \@bad";