I know you'll hate what I am about to say, but I find Perl 5's OO syntax rather ugly. Looks better with your module, but you still have to write classes full of $this->{X} and my $this = shift; that are a nuisance - mostly if compared to the rest of the language and its overall elegance. With your module, the syntax is rather similar to PHP's objects, and it's frankly better than Perl's (no pun intended - really).

Am I the only one feeling that Perl syntax about objects is awful? I believe a language should primarily be a tool to think in, and then a way to tell a computer to do things. I'd better not think in Perl 5 objects....


In reply to Private rant by l3nz
in thread How about class Foo {...} definition for Perl? by gmpassos

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.