in reply to Re: Store only object data but not the whole class
in thread Store only object data but not the whole class

... object creation ... (my preferred syntax):

my $obj =  Whatever::->new();

Just as a matter of curiosity, why do you prefer the trailing  :: in the constructor call?


Give a man a fish:  <%-{-{-{-<

Replies are listed 'Best First'.
Re^3: Store only object data but not the whole class
by kcott (Archbishop) on Aug 31, 2016 at 06:01 UTC
    "Just as a matter of curiosity, why do you prefer the trailing :: in the constructor call?"

    There's a discussion about this in "perlobj: Invoking Class Methods".

    — Ken

Re^3: Store only object data but not the whole class
by NetWallah (Canon) on Aug 30, 2016 at 19:00 UTC
    The "::" makes it clear that the "Whatever" is a package name. Other possible barewords could be "sub", or "File handle".

            "Software interprets lawyers as damage, and routes around them" - Larry Wall