From: Lukas Mai Date: Sat, 17 Nov 2012 23:18:46 +0000 (+0100) Subject: make Moo dependency optional X-Git-Tag: v1.0101~3^2~2 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=af04c6f14fb39ede4662be90662ce829c1cc49d2;p=p5sagit%2FFunction-Parameters.git make Moo dependency optional --- diff --git a/Makefile.PL b/Makefile.PL index 8505863..8713ef9 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -23,7 +23,6 @@ WriteMakefile( }, PREREQ_PM => { 'Carp' => 0, - 'Moo' => 0, 'XSLoader' => 0, 'warnings' => 0, }, diff --git a/lib/Function/Parameters.pm b/lib/Function/Parameters.pm index c67e6ec..31845e8 100644 --- a/lib/Function/Parameters.pm +++ b/lib/Function/Parameters.pm @@ -621,6 +621,9 @@ exported, so you have to call it by its full name). It takes a reference to a function, and returns either C (if it knows nothing about the function) or a L object describing the parameter list. +Note: This feature is implemented using L, so you'll need to have L +installed if you want to call C. + See L for examples. =head2 Wrapping C diff --git a/t/info.t b/t/info.t index 683fa15..57e2696 100644 --- a/t/info.t +++ b/t/info.t @@ -2,7 +2,11 @@ use warnings FATAL => 'all'; use strict; -use Test::More tests => 122; +use Test::More + eval { require Moo; 1 } + ? (tests => 122) + : (skip_all => "Moo required for testing parameter introspection") +; use Function::Parameters;