Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^3: Miscellaneous.pm?

by diotalevi (Canon)
on Mar 03, 2006 at 00:35 UTC ( #534099=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Miscellaneous.pm?
in thread Miscellaneous.pm?

That module is on my to-avoid list. It's poisoned with prototypes and is chock full of functions of dubious utility and quality. Thanks for the note about the bug in my response. I don't make the same mistake when I'm typing at source code.

In general, I'd prefer to inline these sorts of tasks anyway. It's only while experimenting that I use these as broken out functions.

⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊


Comment on Re^3: Miscellaneous.pm?
Re^4: Miscellaneous.pm?
by bart (Canon) on Mar 04, 2006 at 16:23 UTC
    Thanks for the note about the bug in my response. I don't make the same mistake when I'm typing at source code.
    LOL! Yeah, right. You've shown a perfect example why people ought to put such often used code in a module, instead of typing it in, again and again.

      Well I've never made it /before/...

      ⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊

Re^4: Miscellaneous.pm?
by polettix (Vicar) on Mar 06, 2006 at 11:41 UTC
    [List::MoreUtils]... is chock full of functions of dubious utility and quality.
    Could you elaborate a bit about the quality? Just curious, could be an interesting source for guidelines and best practices (and probably a meditation by its own).

    Flavio
    perl -ple'$_=reverse' <<<ti.xittelop@oivalf

    Don't fool yourself.

      I objected most to the use of prototypes everywhere. I might have found one thing I disliked but I was sure I'd get things wrong if I used it because it's a bag of functions and it'd force some particular syntax on me.

      I kind of sort of wish that if the author really believed in those functions that they'd be added to List::Utils directly.

      ⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊

        I don't think to understand thoroughly, but it probably stems from the fact that I'm English impaired.

        About the syntax, it seems to me that the whole point of both List::Util and List::MoreUtils is to try and mimic the celebrated built-ins for dealing with lists, namely sort, grep and map. This is probably why the two modules are "poisoned with prototypes". The net effect is that you don't have to learn a new, particular syntax, just reuse what you're already comfortable with.

        About the interaction between the two modules, AFAIK the author of List::Util was not willing to include other functions inside it, and this basically led to List::MoreUtils. I wouldn't prepare and maintain a module if I wouldn't believe in what I'm putting into it :)

        Flavio
        perl -ple'$_=reverse' <<<ti.xittelop@oivalf

        Don't fool yourself.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://534099]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (17)
As of 2014-07-11 15:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (230 votes), past polls