Your skill will accomplish what the force of many cannot |
|
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Juerd wrote: There is a lot of readability to be gained by just writing it differently:
Minor point: readability is often subjective. I'm not sure if your code is easier to read, but it is more concise. However, it's still not as easy to read (IMHO) is MMD: Major point: Perl has an entire class of bugs not found in other languages and in our debating the merits of how to deal with it, both of us have fallen victim to this bug. Your code has a bug. Specifically, mine does not allow a reference to be assigned to name. Your code does. This seems like a minor nit but this goes to the code of the problem I am trying to solve. Consider the following snippet from the POD of my module:
I didn't intend to put a buggy example in my POD, but my bug and your bug are in the same class of bug. Specifically, forcing programmers to check the number and type of arguments is to shift programming burden to the programmer when it can easily be handled by the computer. I gave a live testing demo at Portland Perl Mongers and many who actually did testing admitted they skip this validation in their actual code unless the code is a critical part of the system. Why should this be done? Most languages provide this validation with signatures (though this still only validates type and not domain.) Cheers, New address of my CGI Course. In reply to Re^2: Use method/function signatures with Perl
by Ovid
|
|