Skip to content

Commit

Permalink
Merge pull request #97 from schwern/bug/experimental
Browse files Browse the repository at this point in the history
Remove 'use experimental', it doesn't work with 5.8.
  • Loading branch information
barefootcoder committed Mar 23, 2014
2 parents fc147d3 + 1b23b08 commit db41c3c
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 10 deletions.
1 change: 0 additions & 1 deletion Build.PL
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ my $build = Module::Build->new(
requires => {
'perl' => '5.8.1',

'experimental' => '0.005',
'Devel::Declare' => '0.006002',
'Devel::Declare::MethodInstaller::Simple' => '0.006002',
'Const::Fast' => '0.006',
Expand Down
7 changes: 2 additions & 5 deletions META.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"Michael G Schwern <schwern@pobox.com>"
],
"dynamic_config" : 1,
"generated_by" : "Module::Build version 0.4005, CPAN::Meta::Converter version 2.131560",
"generated_by" : "Module::Build version 0.4203",
"license" : [
"perl_5"
],
Expand Down Expand Up @@ -42,7 +42,6 @@
"Mouse" : "0.64",
"PPI" : "1.203",
"Sub::Name" : "0.03",
"experimental" : "0.005",
"perl" : "v5.8.1"
}
}
Expand All @@ -68,9 +67,7 @@
"bugtracker" : {
"web" : "http://rt.cpan.org/NoAuth/Bugs.html?Dist=Method-Signatures"
},
"license" : [
"http://dev.perl.org/licenses/"
],
"license" : "http://dev.perl.org/licenses/",
"repository" : {
"url" : "https://github.com/schwern/method-signatures"
}
Expand Down
5 changes: 3 additions & 2 deletions META.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ build_requires:
configure_requires:
Module::Build: 0.26
dynamic_config: 1
generated_by: 'Module::Build version 0.4005, CPAN::Meta::Converter version 2.131560'
generated_by: 'Module::Build version 0.4203, CPAN::Meta::Converter version 2.120921'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
Expand All @@ -26,8 +26,10 @@ provides:
version: 20140224
Method::Signatures::Parameter:
file: lib/Method/Signatures/Parameter.pm
version: 0
Method::Signatures::Parser:
file: lib/Method/Signatures/Parser.pm
version: 0
recommends:
Data::Alias: 1.08
Moose: 0.96
Expand All @@ -40,7 +42,6 @@ requires:
Mouse: 0.64
PPI: 1.203
Sub::Name: 0.03
experimental: 0.005
perl: v5.8.1
resources:
bugtracker: http://rt.cpan.org/NoAuth/Bugs.html?Dist=Method-Signatures
Expand Down
2 changes: 1 addition & 1 deletion lib/Method/Signatures.pm
Original file line number Diff line number Diff line change
Expand Up @@ -1151,7 +1151,7 @@ sub inject_for_sig {
? "sub $constraint"
: $constraint;
my $error = sprintf q{ %s->where_error(%s, '%s', '%s') }, $class, $var, $var, $constraint;
push @code, "$error unless do { use experimental 'smartmatch'; grep { \$_ ~~ $constraint_impl } $var }; ";
push @code, "$error unless do { no if \$] >= 5.017011, warnings => 'experimental::smartmatch'; grep { \$_ ~~ $constraint_impl } $var }; ";
}
}

Expand Down
2 changes: 1 addition & 1 deletion t/where.t
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ subtest 'where { cat => 1, dog => 2}' => sub {


subtest 'where where where' => sub {
use experimental 'smartmatch';
no if $] >= 5.017011, warnings => 'experimental::smartmatch';
plan tests => 14;

func is_prime ($x) {
Expand Down

0 comments on commit db41c3c

Please sign in to comment.