Hi all,

as a regular reader of the Perlweekly newsletter I stumbled on this entry in Edition #170: Stop using indirect object notation.

In the same moment I thought: Didn't I ask something related some time ago? Yes, I did. And I found it: Reference needed.

So, I bring this to awareness once again.

The reactions on twitter are interesting. IMHO the very first action that could be taken: Change all (changeable) documentation where new Class is used. Because most people don't care. They're copy&pasting the examples and synopsis of CPAN modules. And you can find this indirect notation on CPAN.

Regards
McA

Replies are listed 'Best First'.
Re: Reanimating regular issue: Indirect Object Notation
by marto (Cardinal) on Oct 27, 2014 at 10:34 UTC

    "They're copy&pasting the examples and synopsis of CPAN modules. And you can find this indirect notation on CPAN."

    I suppose one could come up with a list of 'offenders' using something like grep.cpan.me/App::cpangrep, with some further work you could automate the creation of a ticket/PR alerting the author to the issue.

    Update: added link to cpan module, fixed typo

Re: Reanimating regular issue: Indirect Object Notation
by McA (Priest) on Oct 27, 2014 at 13:15 UTC

    Gave it a try:

    http://grep.cpan.me/?q=new+%2B[A-Z]

    You can make your own conclusions on the results.

    @Marto: Thank you for the CPAN grep link.

    Regards
    McA