Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Comment on

( #3333=superdoc: print w/ replies, xml ) Need Help??

  1. I don't see unless as being any clearer. I rarely use unless. I consider its real value to be providing a way to not have to say if( ! ( complex combination of Boolean expressions ) ) and other methods often serve that same purpose. I could write:
    if( ! @_ ) if( 0 == @_ ) if( @_ < 1 )
    to list a few. I read the first one as "if no arguments", which is perfectly clear to me, clearer than "unless some arguments". But it all seems rather trivial in this case and any of them (including using unless) would be fine by me. (: (I guess I'm more likely to use unless as a statement modifier, not much for a conditional block.)
  2. use would cause Carp.pm be loaded at compile-time. I don't want to load Carp.pm unless I actually end up needing it. I wouldn't go to this much work in a script, but I pay attention to minor details when writing modules.
  3. Mostly because the code started out simpler and the error handling was expanded later and the code hasn't been refactored since then. :)

Update: dragonchild tells me that the question was more about require Exporter. use would call Exporter->import and I'm not importing anything from Exporter so I see no point in useing it. Even Exporter docs use require and not use.

        - tye (but my friends call me "Tye")

In reply to (tye)Re3: mapcar -- map for more than one list by tye
in thread mapcar -- map for more than one list by tye

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • Outside of code tags, you may need to use entities for some characters:
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others lurking in the Monastery: (5)
    As of 2014-11-22 10:42 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      My preferred Perl binaries come from:














      Results (121 votes), past polls