my point is that a single object instantiation and method call can be something trivial - e.g. adding two numbers...

I guess if you need a script to add 2 to 400, then that is fine.

But what makes Math::BigInt's use of OO useful, is that it provided substantially more than 1 method.

More to the point, it uses the OO methodology to provide facilities that would be difficult if not impossible to provide any other way: namely, the ability to switch transparently between different back-ends, that allow the user to choose their priorities. If they need more speed than the pure Perl implementation provides, they can underpin it with Math::GMP (assuming it builds on their system). Still too slow, but they are prepared to trade some accuracy, they can stick Math::Pari in there instead.

That is well-architected, well-implemented, useful OO Not pseud-OO for its own sake.

(If you don't like the Apache example, then pure Perl Web servers such as Starman are usually not much more than an instantiation plus method call.)

A module -- regardless of what it does -- that provides nothing but a constructor and a single method is a fatuous use of OO: Ie. pseud-OO. A completely, useless, pointless, puerile use of OO for no benefit.

But even then, if the constructor consists of blessing a hash with some data in it, where's the harm. It costs nothing.

But pulling 288 modules into memory to provide pseud-OO -- OO for no benefit or purpose beyond the dogmatic assumption that "OO is better" -- is using OO as nothing more than a fashion accessory. Like a Diamond Encrusted iPhone or a Gold-plated iPad. It's just plain nuts.

App::Reprove does a different task. App::Prove runs one or more test cases that are on the local disk. App::Reprove takes the name of an already installed module, finds its test cases on CPAN, downloads them into a temp dir and runs App::Prove on them.

Exactly! If the module is already installed, so are the tests. Downloading them again is pointless. And using pseud-OO to do it even more so.


With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.

The start of some sanity?


In reply to Re^8: Should I upload it on CPAN? by BrowserUk
in thread Should I upload it on CPAN? by llancet

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!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • 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, details, 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, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            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.