Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
*.swp
/.build/
!/.gitignore
/MooseX-Params-*/
/MooseX-Params-*.tar.gz
9 changes: 5 additions & 4 deletions dist.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@ name = MooseX-Params
author = Peter Shangov <pshangov@yahoo.com>
license = Perl_5
copyright_holder = Peter Shangov
version = 0.010
version = 0.011
abstract = Parameters with meta, laziness and %_

[GatherDir]
[PruneCruft]
[ManifestSkip]
[MetaYAML]
[MetaJSON]
[License]
[ExtraTests]
[ExecDir]
Expand All @@ -26,13 +27,12 @@ skip = TestParent
;[CheckChangesTests]
[Test::Compile]
[Bugtracker]
[ReadmeFromPod]
[GithubMeta]
[PodWeaver]
;Test::Spelling 0.12 no longer works on Win32
;[PodSpellingTests]
[EOLTests]
[NoTabsTests]
[Test::EOL]
[Test::NoTabs]
[PruneFiles]
match = ^docs/*
filename = TODO.mkd
Expand All @@ -41,3 +41,4 @@ Package::Stash = 0.18
Moose = 1.24
[MetaNoIndex]
package = Moose::Util::TypeConstraints
[ReadmeAnyFromPod]
5 changes: 3 additions & 2 deletions lib/MooseX/Params/TypeConstraints.pm
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ use warnings;

use Moose::Util::TypeConstraints;
use MooseX::Params::Meta::TypeConstraint::Listable;
use List::Util 1.33 ();

my $registry = Moose::Util::TypeConstraints::get_type_constraint_registry;

Expand Down Expand Up @@ -35,7 +36,7 @@ $registry->add_type_constraint(
'do {'
. 'my $check = ' . $val . ';'
. 'ref($check) eq "ARRAY" '
. '&& &List::MoreUtils::all('
. '&& &List::Util::all('
. 'sub { ' . $type_parameter->_inline_check('$_') . ' }, '
. '@{$check}'
. ')'
Expand Down Expand Up @@ -71,7 +72,7 @@ $registry->add_type_constraint(
'do {'
. 'my $check = ' . $val . ';'
. 'ref($check) eq "HASH" '
. '&& &List::MoreUtils::all('
. '&& &List::Util::all('
. 'sub { ' . $type_parameter->_inline_check('$_') . ' }, '
. 'values %{$check}'
. ')'
Expand Down