Leader of Birmingham.pm [pm.org] and a CPAN author [cpan.org]. Co-organised YAPC::Europe in 2006 and the 2009 QA Hackathon, responsible for the YAPC Conference Surveys [yapc-surveys.org] and the QA Hackathon [qa-hackathon.org] websites. Also the current caretaker for the CPAN Testers websites and data stores.
If you really want to find out more, buy me a Guinness
Links:
Memoirs of a Roadie [missbarbell.co.uk]
[pm.org]
CPAN Testers Reports [cpantesters.org]
YAPC Conference Surveys [yapc-surveys.org]
QA Hackathon [qa-hackathon.org]
As a consequence of my testing I also realised that my naive method of copying a hash to a hash, was a bit flaw. Okay, a lot flawed. I had a quick look on CPAN and found the funky Clone, which does exactly what I want
While looking at the recently uploaded modules list, I also spotted a nice little module, Params::Check. I'm a little bit gutted as I have been implementing something similar for sometime, but never thought to wrap it up into a nice neat module for CPAN. The module extends beyond my code, so I'm hoping to incorporate the module into my apps. However, I do have some misgivings.
Params::Check will do the following things for you:
- Convert all keys to lowercase
- Weed out arguments that are not supported and warn about them to the user
The first is a little presumptuous. I use UPPER, Mixed and lower case parameter names to indicate different things, having them forced to lower case is not a good one. It should be up to the user. I suggest another global variable of $Params::Check::TO_LOWER.
The second again assumes you must have warnings. I always thought warnings, by their very nature, were an optional thing. So why again force the user to handle them. The default should be to ignore warnings and let the user decide if they want them or not.
In addition I also have some paramater names, which have a suffix corresponding to a numeric id. It would be nice to have another key rule (along the lines of 'allow') for 'suffix'.
I have emailed Jos with my suggestions, so I'll wait and see whether he thinks they're worth adding. If I have time I will try and write a patch, but certainly for this week, thats doubtful. Though having said all that, I do think think this has the makings of a well used module.
It wasn't my intention when I started this entry, but I think this is the most hyperlinked entry I've written. Perhaps I should calm down now.
dclone (Score:3, Informative)
Reply to This
Re:dclone (Score:1)
However, I suspect most will install on Windows via PPM and ActiveState have a version in their repository. So probably not as bigger pain as you might think :) Certainly installed on my Win2K box in a few seconds.