Re: Arguments checker module

2009-05-05 Thread breno
On Wed, May 6, 2009 at 2:59 AM, Bill Ward wrote: > Do you mean Parse::Method::Signatures ? > No, I mean http://search.cpan.org/perldoc?Method::Signatures http://www.slideshare.net/schwern/methodsignatures-presentation I haven't looked at it much, but it seems to fill most of your needs (not tied

Re: Arguments checker module

2009-05-05 Thread Bill Ward
Do you mean Parse::Method::Signatures ? On Tue, May 5, 2009 at 10:54 PM, breno wrote: > On Wed, May 6, 2009 at 12:04 AM, Bill Ward wrote: > > > > Params::Validate has the right features, but I really don't like the > > verbosity of its configuration. I was hoping for something more like the >

Re: Arguments checker module

2009-05-05 Thread breno
On Wed, May 6, 2009 at 12:04 AM, Bill Ward wrote: > > Params::Validate has the right features, but I really don't like the > verbosity of its configuration.  I was hoping for something more like the > Perl prototyping or Getopt::Long syntax.  Maybe I'll write a wrapper around > Params::Validate? >

Re: Arguments checker module

2009-05-05 Thread Bill Ward
On Tue, May 5, 2009 at 8:27 PM, Hans Dieter Pearcey < hdp.perl.module-auth...@weftsoar.net> wrote: > On Tue, May 05, 2009 at 08:04:35PM -0700, Bill Ward wrote: > > I'm not interested in being locked-in to a framework like Moose, so I > won't > > even consider those. > > > http://search.cpan.org/~d

Re: Arguments checker module

2009-05-05 Thread Hans Dieter Pearcey
On Tue, May 05, 2009 at 08:04:35PM -0700, Bill Ward wrote: > I'm not interested in being locked-in to a framework like Moose, so I won't > even consider those. http://search.cpan.org/~drolsky/Moose-0.77/lib/Moose/Util/TypeConstraints.pm#Use_with_Other_Constraint_Modules Moose's type constraints s

Re: Arguments checker module

2009-05-05 Thread Bill Ward
On Tue, May 5, 2009 at 7:55 PM, Dave Rolsky wrote: > On Tue, 5 May 2009, Bill Ward wrote: > > I'm often having to add a half dozen lines of code to every subroutine to >> perform argument validation and I'd like to offload it once and for all >> into >> a CPAN module. Has anyone written or seen

Re: Arguments checker module

2009-05-05 Thread Bill Ward
On Tue, May 5, 2009 at 7:55 PM, Hans Dieter Pearcey < hdp.perl.module-auth...@weftsoar.net> wrote: > On Tue, May 05, 2009 at 07:51:09PM -0700, Bill Ward wrote: > > I'm often having to add a half dozen lines of code to every subroutine to > > perform argument validation and I'd like to offload it o

Re: Arguments checker module

2009-05-05 Thread Dave Rolsky
On Tue, 5 May 2009, Bill Ward wrote: I'm often having to add a half dozen lines of code to every subroutine to perform argument validation and I'd like to offload it once and for all into a CPAN module. Has anyone written or seen such a beast? I haven't, so I've started writing it... but then,

Re: Arguments checker module

2009-05-05 Thread Hans Dieter Pearcey
On Tue, May 05, 2009 at 07:51:09PM -0700, Bill Ward wrote: > I'm often having to add a half dozen lines of code to every subroutine to > perform argument validation and I'd like to offload it once and for all into a > CPAN module. Has anyone written or seen such a beast? I haven't, so I've > star

Arguments checker module

2009-05-05 Thread Bill Ward
Is anyone aware of any modules that will check subroutine arguments? I can think of two similar features of Perl, but neither is quite right: 1. Prototypes (perlsyn) - put something like ($$@) after your subroutine declaration - but doesn't work for object methods and a few other cases. Plus, doe

Re: Dual-Build Modules (What to do if both Makefile.PL and Build.PL exist)

2009-05-05 Thread David Golden
On Tue, May 5, 2009 at 10:06 PM, Jonathan Yu wrote: > Add to this some complication from Module::Install, which also uses > Makefile.PL. So in that case maybe Makefile.PL is preferred (for > Module::Install to do its thing) rather than Build.PL. (On the other > hand, I don't think I've seen module

Re: Dual-Build Modules (What to do if both Makefile.PL and Build.PL exist)

2009-05-05 Thread Bill Ward
The way I've interpreted that in my own auto-build scripting is that if Build.PL exists, the module author is probably a Module::Build user who is only providing a Makefile.PL grudgingly for the sake of those who haven't installed Module::Build, and thus I figure that if there's any difference betw

Dual-Build Modules (What to do if both Makefile.PL and Build.PL exist)

2009-05-05 Thread Jonathan Yu
Hi wise Perl authors: I've been building some Perl packages for Debian. I've noticed in the course of this that dh-make-perl (our preferred script for transforming Perl distributions into Debian packages) prefers Makefile.PL over Build.PL. One problem this has caused is that a Makefile is created

Re: Puzzling error from cpan testers

2009-05-05 Thread Jonathan Leto
Howdy, > Yikes.  You must have missed Test::Number::Delta when you were writing > that.  On CPAN since 2005.  I originally called it Test::Float and got > argued into a proper hierarchical name, which is probably why no one > seems to know it exists.   Synopsis: No, I saw your module, but I neede

Re: Puzzling error from cpan testers

2009-05-05 Thread Bill Ward
Thanks David. This is a nice module, but overkill for my needs and I'd rather not make people install more CPAN modules than they have to. Looks like the key thing is this line: $ok = abs($p - $q) < $epsilon; I'll incorporate that bit into my test suite for Number::Format. On Tue, May

Re: Puzzling error from cpan testers

2009-05-05 Thread David Golden
On Tue, May 5, 2009 at 2:58 PM, Jonathan Leto wrote: > I very much recommend that you look at is_similar() in > Math::GSL::Test, it has implemented at least a > few wheels that you are destined to want: Yikes. You must have missed Test::Number::Delta when you were writing that. On CPAN since 20

Re: Puzzling error from cpan testers

2009-05-05 Thread Jonathan Leto
Howdy, >> It may work, or it may not.  If it "works" - in the sense of making the >> test failure go away - then I would expect it to bite someone later when >> they just happen to hit upon a number where the floating point rounding >> error goes the other way. >> >> Check that it's in an acceptab

Re: Puzzling error from cpan testers

2009-05-05 Thread Bill Ward
On Tue, May 5, 2009 at 6:02 AM, David Cantrell wrote: > On Sun, May 03, 2009 at 12:23:27PM -0700, Bill Ward wrote: > > On Sun, May 3, 2009 at 12:18 PM, Andy Armstrong wrote: > > > On 3 May 2009, at 20:07, Bill Ward wrote: > > >> For my module Number::Format I am getting a strange result from cpan

Re: Puzzling error from cpan testers

2009-05-05 Thread David Cantrell
On Sun, May 03, 2009 at 12:23:27PM -0700, Bill Ward wrote: > On Sun, May 3, 2009 at 12:18 PM, Andy Armstrong wrote: > > On 3 May 2009, at 20:07, Bill Ward wrote: > >> For my module Number::Format I am getting a strange result from cpan > >> testers that I can't replicate. See this error report...